KFSG#70107 BESOTV-notificatiejob (hard-coded voor Xerox en Staples)

svn path=/Customer/trunk/; revision=55497
This commit is contained in:
Maarten van der Heide
2022-04-05 09:06:10 +00:00
parent 17880e12c5
commit 2fbbb5ef99

View File

@@ -4356,6 +4356,7 @@ AS
-- KFSG#70107: BESOTV-notificatie, die standaard (bewust) staat uitgeschakeld,
-- alsnog versturen als CUST04-notificatie voor sommige catalogi.
-- Op speciaal verzoek hard-coded (ipv. bes_disc_params_noti_dagen)!
CREATE OR REPLACE VIEW KFSG_V_NOTI_BESOTV
(
CODE,
@@ -4386,7 +4387,7 @@ AS
bes_bestelling_item bi,
bes_srtdeel sd,
bes_srtgroep sg,
bes_disc_params dp,
--bes_disc_params dp,
fac_srtnotificatie sn,
fac_notificatie_job nj
WHERE t.fac_srtnotificatie_key = 9 -- BESOTV
@@ -4394,8 +4395,9 @@ AS
AND b.bes_bestelling_key = bi.bes_bestelling_key
AND bi.bes_srtdeel_key = sd.bes_srtdeel_key
AND sd.bes_srtgroep_key = sg.bes_srtgroep_key
AND sg.ins_discipline_key = dp.bes_ins_discipline_key
AND dp.bes_disc_params_noti_dagen = 1
--AND sg.ins_discipline_key = dp.bes_ins_discipline_key
--AND dp.bes_disc_params_noti_dagen = 1
AND sg.ins_discipline_key IN (1121, 1122) -- Reproductie=Xerox/Kantoorartikelen=Staples
AND sn.fac_srtnotificatie_code = 'CUST04'
AND nj.fac_notificatie_job_view = 'KFSG_V_NOTI_BESOTV'
AND t.fac_tracking_datum > nj.fac_notificatie_job_lastrun;