diff --git a/src-modules/module/costage/conf/costage.xml b/src-modules/module/costage/conf/costage.xml index 40f6b1d..2be3077 100644 --- a/src-modules/module/costage/conf/costage.xml +++ b/src-modules/module/costage/conf/costage.xml @@ -290,6 +290,8 @@ rightname="CS_BIA_STANDARDREPORTS_ADMIN[CO]" /> + + diff --git a/src-modules/module/costage/masken/43040_felderinfo.unl b/src-modules/module/costage/masken/43040_felderinfo.unl index f77626d..0c765d1 100644 --- a/src-modules/module/costage/masken/43040_felderinfo.unl +++ b/src-modules/module/costage/masken/43040_felderinfo.unl @@ -52,8 +52,22 @@ order by 2\ 43054^Schlüssel anzeigen^150^0^0^100^100^1^integer^30^1^1^<> select 1,'Ja' from xdummy union select 0,'Nein' from xdummy^^<> select 1,'Ja' from xdummy^ 43055^tablestylesheet^121^0^0^100^200^1^char^200^1^1^<> select distinct filename,X.caption,ord from sx_stylesheets X,sx_mask_style S where X.tid=S.stylesheet_id and S.maskeninfo_id=43040 order by ord^^<> select distinct filename,X.caption from sx_stylesheets X,sx_mask_style S where X.tid=S.stylesheet_id and S.maskeninfo_id=43040 and S.ord=1^ 43056^Ausgabeformat^2001^0^0^100^150^1^char^200^1^1^<> select element_value,description from menu_element where element='Ausgabeformat' and nature::smallint<100 order by nature::smallint^^<> select element_value,description from menu_element where element='Ausgabeformat' and description='HTML'^ -43059^Hochschule^5^350^-1^140^80^1^char^255^0^1^<>select distinct K.unikey,K.unikey\ +43059^Hochschule / Standort^5^350^-1^140^80^1^char^255^0^1^<> --freemarker template \ +<#if COSTAGE_STORT?exists && COSTAGE_STORT !="">\ +<#assign inlineTemplate=COSTAGE_STORT?interpret />\ +<@inlineTemplate/>\ +\ +<#if stort?exists>\ +<#foreach st in stort>\ +select '${st.nr}','${st.name}' from xdummy\ +<#if st?has_next>\ +union\ +\ +\ +<#else>\ +select distinct K.unikey,K.unikey\ from costage_st_studienkennzahlen K\ +\ order by 2;^ ^<> select distinct K.unikey,K.unikey\ from costage_st_studienkennzahlen K, hochschulinfo H\ where K.unikey=H.hs_nr::char(10)^ diff --git a/src-modules/module/costage/masken/43040_maskeninfo.unl b/src-modules/module/costage/masken/43040_maskeninfo.unl index 9eb8d24..0423496 100644 --- a/src-modules/module/costage/masken/43040_maskeninfo.unl +++ b/src-modules/module/costage/masken/43040_maskeninfo.unl @@ -75,7 +75,7 @@ SELECT name,\ /* and fach_nr =<> */\ /* and costage_st_studien_aggr.st_studstamm_nr in (select S.st_studstamm_nr from costage_st_studierendenstammdaten S where S.st_land1_nr in (<>) ) */\ /* and costage_st_studien_aggr.st_studstamm_nr in (select S2.st_studstamm_nr from costage_st_studierendenstammdaten S2 where S2.geschlecht = <> ) */\ -/* and costage_st_studien_aggr.unikey=<> */\ +/* and costage_st_studien_aggr.unikey=<> */\ " />\ \ \ diff --git a/src-modules/module/costage/rohdaten_sos/sos_costage_unload.xml b/src-modules/module/costage/rohdaten_sos/sos_costage_unload.xml index 24cb89f..0604a15 100644 --- a/src-modules/module/costage/rohdaten_sos/sos_costage_unload.xml +++ b/src-modules/module/costage/rohdaten_sos/sos_costage_unload.xml @@ -241,6 +241,7 @@ and F.kz_rueck_beur_ein is not null AND F.semester >= $start_stud_sem and ($EXTERNAL_SUBJECTS ='true' or F.unikey=(select H.hs_nr::char(10) from hochschulinfo H) +or exists(select id from sx_repository R where R.id='COSTAGE_STORT' and aktiv=1) ) ; @@ -512,6 +513,7 @@ null as sortorder on ( F.st_stdfach_nr=K.st_stdfach_nr) where ($EXTERNAL_SUBJECTS ='true' or unikey=(select H.hs_nr::char(10) from hochschulinfo H) +or exists(select id from sx_repository R where R.id='COSTAGE_STORT' and aktiv=1) ) union diff --git a/src-modules/module/costage/rohdaten_zul/zul_costage_unload.xml b/src-modules/module/costage/rohdaten_zul/zul_costage_unload.xml index a8feedf..34b4917 100644 --- a/src-modules/module/costage/rohdaten_zul/zul_costage_unload.xml +++ b/src-modules/module/costage/rohdaten_zul/zul_costage_unload.xml @@ -279,6 +279,7 @@ where A.st_studiengang_nr=G.st_studiengang_nr and A.bw_typ_kb !='MBW' and ($EXTERNAL_SUBJECTS ='true' or A.unikey=(select H.hs_nr::char(10) from hochschulinfo H) +or exists(select id from sx_repository R where R.id='COSTAGE_STORT' and aktiv=1) ) ; @@ -548,7 +549,29 @@ from costage_st_land_regionen R, costage_st_laender L where L.st_land_nr=R.st_land_nr and L.statistik_code='000' and R.statistik_code is not null - +union + SELECT distinct + 9012, +0, + stort_nr, + stort_nr as ktxt, + stort_name as dtxt, + stort_name as ltxt , +stort_nr as astat, +' ', +stort_nr as uniquename, +null::integer as sortorder, +' ' as bund_apnr, +' ', --sprache +null::date as gueltig_von, +null::date as gueltig_bis, +stort_nr::varchar(255), --sourcesystem_id +null::char(10) , --hiskey_id +null as struktur_c, +null as lid, +null as parent_lid +FROM costage_st_studiengaenge +; ]]> diff --git a/src-modules/module/costage/schluesseltabellen/sx_repository.unl b/src-modules/module/costage/schluesseltabellen/sx_repository.unl index b3f6de5..78888bc 100644 --- a/src-modules/module/costage/schluesseltabellen/sx_repository.unl +++ b/src-modules/module/costage/schluesseltabellen/sx_repository.unl @@ -1 +1,2 @@ 1^COSTAGE_STUDENT_FILTER^1=1^Filter Studierende für CO^Hier werden Studierende für Auswertungen aus CO gefiltert^^COSTAGE_STUD_FILTER^^^310^1^0^0^^1^01.01.1900^31.12.3000^ +2^COSTAGE_STORT^^Standorte^Hier werden Standorte konfiguriert^^COSTAGE_STORT^^^310^1^0^0^^0^01.01.1900^31.12.3000^ diff --git a/src-modules/module/costage/schluesseltabellen/trans_costage_st_studiengaenge.sql b/src-modules/module/costage/schluesseltabellen/trans_costage_st_studiengaenge.sql index e6dd3d9..7e7f7df 100644 --- a/src-modules/module/costage/schluesseltabellen/trans_costage_st_studiengaenge.sql +++ b/src-modules/module/costage/schluesseltabellen/trans_costage_st_studiengaenge.sql @@ -1,3 +1,10 @@ +--freemarker template +<#if COSTAGE_STORT?exists && COSTAGE_STORT !=""> +<#assign inlineTemplate=COSTAGE_STORT?interpret /> +<@inlineTemplate/> + + + delete from costage_st_studiengaenge; @@ -33,6 +40,9 @@ st_studiengang_nr, --transformiere Fach/Abschluss etc. nach SuperX Notation --Fach: update costage_st_studiengaenge set skz_key=SKZ.skz_key +<#if stort?exists> +,stort_nr=SKZ.unikey + from costage_st_studienkennzahlen SKZ where SKZ.st_skz_nr=costage_st_studiengaenge.st_skz_nr; --Abschluss: @@ -49,3 +59,12 @@ and S.st_studiengang_nr=costage_st_studiengaenge.st_studiengang_nr --paßt nicht zusammen: and P.stp_stp_nr=costage_st_studiengaenge.stp_stp_nr ; +--Standorte name: + +<#if stort?exists> +<#foreach st in stort> +update costage_st_studiengaenge set stort_name='${st.name}' +where stort_nr='${st.nr}'; + + + diff --git a/src-modules/module/costage/schluesseltabellen/trans_costage_st_studienkennzahlen.sql b/src-modules/module/costage/schluesseltabellen/trans_costage_st_studienkennzahlen.sql index d305918..22bcf29 100644 --- a/src-modules/module/costage/schluesseltabellen/trans_costage_st_studienkennzahlen.sql +++ b/src-modules/module/costage/schluesseltabellen/trans_costage_st_studienkennzahlen.sql @@ -1,3 +1,8 @@ +--freemarker template +<#if COSTAGE_STORT?exists && COSTAGE_STORT !=""> +<#assign inlineTemplate=COSTAGE_STORT?interpret /> +<@inlineTemplate/> + delete from costage_st_studienkennzahlen; @@ -20,7 +25,16 @@ S.st_stdfach_nr, S.gesetzliche_grundlage_kb FROM costage_st_studienkennzahlen_neu S, hochschulinfo H where H.hs_nr::char(10)=S.unikey or S.unikey is null +or 1=0 +<#if stort?exists> +<#foreach st in stort> +or S.unikey ='${st.nr}' + + ; + +<#if stort?exists == false> + --wg. Eindeutigkeit kombinierter Schlüssel SKZ+UNIKEY: insert into costage_st_studienkennzahlen( st_skz_nr, @@ -42,5 +56,5 @@ S.gesetzliche_grundlage_kb FROM costage_st_studienkennzahlen_neu S, hochschulinfo H where H.hs_nr::char(10)!=S.unikey ; - + --TODO: Duplikatssuche bei Fächern ("skz_key").