diff --git a/src-modules/module/xcube/schluesseltabellen/xcube_install_restrictions.sql b/src-modules/module/xcube/schluesseltabellen/xcube_install_restrictions.sql index 5300546..9ad02c5 100644 --- a/src-modules/module/xcube/schluesseltabellen/xcube_install_restrictions.sql +++ b/src-modules/module/xcube/schluesseltabellen/xcube_install_restrictions.sql @@ -40,6 +40,12 @@ update xcube set restriction='<> --Personalwürfel update xcube set restriction=' + <#assign datum_stichtag=''''> + <#if "<>" =""> + <#assign datum_stichtag="(select stichtag from sva_stichtag where bereich=''p'' and beschreibung=''Tagesdatum'')"/> + <#else> + <#assign datum_stichtag="(select stichtag from sva_stichtag where tid = <>)"/> + <#if "<>" =""> stichtag = (select tid from sva_stichtag where bereich=''p'' and beschreibung=''Tagesdatum'') <#else> stichtag = <> @@ -49,7 +55,11 @@ update xcube set restriction='<> /* AND kostenstelle in <@printkeys .vars["Kostenstelle (Person)"].allNeededKeysList/> --<> */ /* AND ca107_dienstart in <@printkeys Dienstart.allNeededKeysList/> --<> */ /* AND ca109_key_bvl in <@printkeys .vars["BVL-Gruppe"].allNeededKeysList/> --<> */ - ' where maskeninfo_id=21200; + /* AND ca108_amtsbez in <@printkeys Amtsbezeichnung.allNeededKeysList/> --<> */ + /* AND vertart in <@printkeys Vertragsart.allNeededKeysList/> --<> */ +/* and trunc((${datum_stichtag} - geburtsdatum) / 365.25 , 0) <= <> */ + + ' where maskeninfo_id=21200; update xcube set restriction='