Explorar el Código

added ZaliczkiPozycjeVIEW create info

Piotr Labudda hace 9 años
padre
commit
95568f89ba
Se han modificado 1 ficheros con 7 adiciones y 0 borrados
  1. 7 0
      SE/se-lib/Route/UrlAction/UserProNetMediaZaliczka.php

+ 7 - 0
SE/se-lib/Route/UrlAction/UserProNetMediaZaliczka.php

@@ -656,5 +656,12 @@ insert into `ZALICZKA` (`L_APPOITMENT_USER`, `KWOTA`) values('{$data['worker']['
 $data = [ id => 123, pozycja => [ [ kwota => 200.00, korespondencja => [ ... ], projekt => [ ... ] ] ] ]
 update `ZALICZKA__#REF__POZYCJA` set `A_STATUS` = 'DELETED' where `PRIMARY_KEY` = 123;
 
+# 2017-04-11 - pozycje view do exportu
+create view `ZaliczkiPozycjeVIEW` as
+	SELECT z.ID as NR_ZALICZKI
+	   , p.*
+	FROM `ZALICZKA` z
+		join `Zaliczka__#REF__pozycja` r on(r.PRIMARY_KEY = z.ID and r.A_STATUS not in ('DELETED'))
+		join `ZALICZKA_POZYCJA` p on(p.ID = r.REMOTE_PRIMARY_KEY)
 
 */