EBNF#81061 Implementatie EBN, ook notificatie Vergader-reserveringen op evenementzalen

svn path=/Customer/trunk/; revision=64779
This commit is contained in:
Sander Schepers
2024-05-23 11:05:55 +00:00
parent 00c5e73909
commit cc1ff9928f

View File

@@ -402,8 +402,9 @@ CREATE OR REPLACE VIEW EBNF_V_CATERINGRESER
RRR_KEY,
RESERVERING_KEY,
RES_RSV_RUIMTE_VOLGNR,
RES_ACTIVITEIT_KEY,
RES_ACTIVITEIT_KEY,
ACTIVITEIT,
RES_RUIMTE_KEY,
AANMK_DATUM,
LAST_UPD,
LAST_EXPORT,
@@ -426,6 +427,7 @@ AS
"RES_RSV_RUIMTE_VOLGNR",
"RES_ACTIVITEIT_KEY",
"RES_ACTIVITEIT_OMSCHRIJVING",
"RES_RUIMTE_KEY",
"AANMK_DATUM",
"LAST_UPD",
"LAST_EXPORT",
@@ -449,6 +451,7 @@ AS
rrr.res_rsv_ruimte_volgnr,
ra.res_activiteit_key,
ra.res_activiteit_omschrijving,
rer.res_ruimte_key,
rrr.res_rsv_ruimte_aanmaak
aanmk_datum,
(SELECT MAX (fac_tracking_datum)
@@ -509,6 +512,7 @@ AS
rrr.res_rsv_ruimte_volgnr,
ra.res_activiteit_key,
ra.res_activiteit_omschrijving,
NULL,
rrr.res_rsv_ruimte_aanmaak
aanmk_datum,
(SELECT MAX (fac_tracking_datum)
@@ -553,7 +557,7 @@ AS
WHERE rra.RES_RSV_RUIMTE_KEY = rrr.RES_RSV_RUIMTE_KEY
AND alg.alg_ruimte_key = rrr.alg_ruimte_key
AND rrr.res_activiteit_key = ra.res_activiteit_key
ORDER BY reservering_key);
ORDER BY reservering_key);
CREATE OR REPLACE VIEW EBNF_V_NOTI_CATERAAR
(
@@ -582,7 +586,12 @@ AS
WHERE nj.fac_notificatie_job_view = 'EBNF_V_NOTI_CATERAAR'
AND ( nj.fac_notificatie_job_lastrun IS NULL
OR aanmk_datum > nj.fac_notificatie_job_lastrun)
AND res_activiteit_key = 30 --Evenement
AND ( res_activiteit_key = 30 --Evenement
OR ( res_activiteit_key = 10 --Vergadering
AND res_ruimte_key IN (SELECT res_ruimte_key
FROM res_ruimte
WHERE res_discipline_key = 62) --Evenementzalen
))
AND TRUNC (aanmk_datum) = TRUNC (SYSDATE)
AND last_upd IS NULL
AND verw_datum IS NULL
@@ -602,7 +611,12 @@ AS
WHERE nj.fac_notificatie_job_view = 'EBNF_V_NOTI_CATERAAR'
AND ( nj.fac_notificatie_job_lastrun IS NULL
OR LAST_UPD > nj.fac_notificatie_job_lastrun)
AND res_activiteit_key = 30 --Evenement
AND ( res_activiteit_key = 30 --Evenement
OR ( res_activiteit_key = 10 --Vergadering
AND res_ruimte_key IN (SELECT res_ruimte_key
FROM res_ruimte
WHERE res_discipline_key = 62) --Evenementzalen
))
AND TRUNC (LAST_UPD) = TRUNC (SYSDATE)
AND last_upd > aanmk_datum
AND verw_datum IS NULL
@@ -621,8 +635,13 @@ AS
FROM EBNF_V_CATERINGRESER, fac_notificatie_job nj
WHERE nj.fac_notificatie_job_view = 'EBNF_V_NOTI_CATERAAR'
AND ( (verw_datum > nj.fac_notificatie_job_lastrun)
OR nj.fac_notificatie_job_lastrun IS NULL)
AND res_activiteit_key = 30 --Evenement
OR nj.fac_notificatie_job_lastrun IS NULL)
AND ( res_activiteit_key = 30 --Evenement
OR ( res_activiteit_key = 10 --Vergadering
AND res_ruimte_key IN (SELECT res_ruimte_key
FROM res_ruimte
WHERE res_discipline_key = 62) --Evenementzalen
))
AND TRUNC (VERW_DATUM) = TRUNC (SYSDATE);
------ payload end ------