Merge branch 'master' into feature-55978/infocenter_electronic_onboarding_filter

This commit is contained in:
Andreas Österreicher
2025-06-16 11:35:49 +02:00
408 changed files with 26490 additions and 4489 deletions
+7 -3
View File
@@ -61,6 +61,7 @@ require_once('dbupdate_3.4/41134_C4_bookmark_dashboardWidget.php');
require_once('dbupdate_3.4/28575_softwarebereitstellung.php');
require_once('dbupdate_3.4/41150_oe-pfad_db_view.php');
require_once('dbupdate_3.4/44031_stv_favorites.php');
require_once('dbupdate_3.4/37620_reihungslisten.php');
require_once('dbupdate_3.4/40896_kennzeichnung_unruly_person.php');
require_once('dbupdate_3.4/39911_tabulator_in_contentmittitel.php');
require_once('dbupdate_3.4/25999_C4_permission.php');
@@ -70,6 +71,9 @@ require_once('dbupdate_3.4/48526_pep_tagging.php');
require_once('dbupdate_3.4/41950_perm_gehaelter.php');
require_once('dbupdate_3.4/53903_valorisierung.php');
require_once('dbupdate_3.4/55968_index_anrechnung.php');
require_once('dbupdate_3.4/25999_locale_update.php');
require_once('dbupdate_3.4/55289_pep_fine_tuning.php');
require_once('dbupdate_3.4/55614_perm_verwaltetoe.php');
// *** Pruefung und hinzufuegen der neuen Attribute und Tabellen
echo '<H2>Pruefe Tabellen und Attribute!</H2>';
@@ -188,7 +192,7 @@ $tabellen=array(
"fue.tbl_ressource" => array("ressource_id","student_uid","mitarbeiter_uid","betriebsmittel_id","firma_id","bezeichnung","beschreibung","insertamum","insertvon","updateamum","updatevon"),
"fue.tbl_scrumteam" => array("scrumteam_kurzbz","bezeichnung","punkteprosprint","tasksprosprint","gruppe_kurzbz"),
"fue.tbl_scrumsprint" => array("scrumsprint_id","scrumteam_kurzbz","sprint_kurzbz","sprintstart","sprintende","insertamum","insertvon","updateamum","updatevon"),
"hr.tbl_sachaufwand" => array("sachaufwand_id","mitarbeiter_uid","sachaufwandtyp_kurzbz","dienstverhaeltnis_id","beginn","ende","anmerkung","insertamum","insertvon","updateamum","updatevon"),
"hr.tbl_sachaufwand" => array("sachaufwand_id","mitarbeiter_uid","sachaufwandtyp_kurzbz","dienstverhaeltnis_id","beginn","ende","anmerkung","insertamum","insertvon","updateamum","updatevon","betrag"),
"hr.tbl_sachaufwandtyp" => array("sachaufwandtyp_kurzbz","bezeichnung","sort", "aktiv"),
"hr.tbl_stundensatz" => array("stundensatz_id","uid","stundensatztyp","stundensatz","oe_kurzbz","gueltig_von","gueltig_bis","insertamum","insertvon","updateamum","updatevon"),
"hr.tbl_stundensatztyp" => array("stundensatztyp","bezeichnung","aktiv","insertamum","insertvon","updateamum","updatevon"),
@@ -209,7 +213,7 @@ $tabellen=array(
"hr.tbl_teilzeittyp" => array("teilzeittyp_kurzbz","bezeichnung","aktiv"),
"hr.tbl_gehaltsbestandteil" => array("gehaltsbestandteil_id","dienstverhaeltnis_id","vertragsbestandteil_id","gehaltstyp_kurzbz","von","bis","anmerkung","grundbetrag","betrag_valorisiert","valorisierungssperre","insertamum", "insertvon","updateamum","updatevon","valorisierung","auszahlungen"),
"hr.tbl_gehaltshistorie" => array("gehaltshistorie_id", "datum","betrag","gehaltsbestandteil_id","mitarbeiter_uid","gehaltsbestandteil_von","gehaltsbestandteil_bis"),
"hr.tbl_gehaltstyp" => array("gehaltstyp_kurzbz","bezeichnung","valorisierung","sort","aktiv"),
"hr.tbl_gehaltstyp" => array("gehaltstyp_kurzbz","bezeichnung","valorisierung","sort","aktiv","lvexport","lvexport_sum"),
"hr.tbl_frist" => array("frist_id","mitarbeiter_uid","ereignis_kurzbz","bezeichnung","datum","status_kurzbz","parameter","insertvon","insertamum","updatevon","updateamum"),
"hr.tbl_frist_ereignis" => array("ereignis_kurzbz","bezeichnung","manuell","sort"),
"hr.tbl_frist_status" => array("status_kurzbz", "bezeichnung","sort"),
@@ -269,7 +273,7 @@ $tabellen=array(
"lehre.tbl_zeitfenster" => array("wochentag","stunde","ort_kurzbz","studiengang_kz","gewicht"),
"lehre.tbl_zeugnis" => array("zeugnis_id","student_uid","zeugnis","erstelltam","gedruckt","titel","bezeichnung","updateamum","updatevon","insertamum","insertvon","ext_id"),
"lehre.tbl_zeugnisnote" => array("lehrveranstaltung_id","student_uid","studiensemester_kurzbz","note","uebernahmedatum","benotungsdatum","bemerkung","updateamum","updatevon","insertamum","insertvon","ext_id","punkte"),
"lehre.tbl_lehrveranstaltung_faktor" => array("lehrveranstaltung_faktor_id", "lehrveranstaltung_id","faktor","studiensemester_kurzbz_von","studiensemester_kurzbz_bis","insertamum","insertvon","updateamum","updatevon"),
"lehre.tbl_lehrveranstaltung_faktor" => array("lehrveranstaltung_faktor_id", "lehrveranstaltung_id","faktor", "lehrform_kurzbz", "studiensemester_kurzbz_von","studiensemester_kurzbz_bis","insertamum","insertvon","updateamum","updatevon"),
"public.ci_apikey" => array("apikey_id","key","level","ignore_limits","date_created"),
"public.tbl_adresse" => array("adresse_id","person_id","name","strasse","plz","ort","gemeinde","nation","typ","heimatadresse","zustelladresse","firma_id","updateamum","updatevon","insertamum","insertvon","ext_id","rechnungsadresse","anmerkung", "co_name"),
"public.tbl_adressentyp" => array("adressentyp_kurzbz", "bezeichnung", "bezeichnung_mehrsprachig", "sort"),
@@ -0,0 +1,18 @@
<?php
if ($result = $db->db_query("SELECT * FROM information_schema.columns WHERE column_name = 'lc_time' AND table_name = 'tbl_sprache' AND table_schema = 'public';")) {
if ($db->db_num_rows($result) == 0)
{
$qry = "
ALTER TABLE public.tbl_sprache ADD lc_time VARCHAR(255) ;
UPDATE public.tbl_sprache SET lc_time = 'en-GB' where locale ='en-US';
UPDATE public.tbl_sprache SET lc_time = 'de-AT' where locale ='de-AT';
";
if (!$db->db_query($qry))
echo '<strong>public.tbl_sprache: ' . $db->db_last_error() . '</strong><br>';
else
echo '<br>public.tbl_sprache: column lc_time was successfully added';
}
}
+129
View File
@@ -605,4 +605,133 @@ if ($result = $db->db_query("SELECT * FROM information_schema.columns WHERE colu
else
echo 'Spalte gehaltsbestandteil_bis wurde in hr.tbl_gehaltshistorie neu erstellt<br>';
}
}
if ($result = $db->db_query("SELECT * FROM information_schema.columns WHERE column_name='betrag' AND table_name='tbl_sachaufwand' AND table_schema='hr'"))
{
if ($db->db_num_rows($result) == 0)
{
$qry = "
ALTER TABLE
hr.tbl_sachaufwand
ADD COLUMN
betrag numeric(9,2)
";
if (! $db->db_query($qry))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'Spalte betrag wurde in hr.tbl_sachaufwand neu erstellt<br>';
}
}
if ($result = $db->db_query("SELECT * FROM information_schema.columns WHERE column_name='lvexport' AND table_name='tbl_gehaltstyp' AND table_schema='hr'"))
{
if ($db->db_num_rows($result) == 0)
{
$qry = "
ALTER TABLE
hr.tbl_gehaltstyp
ADD COLUMN
lvexport boolean NOT NULL DEFAULT true;
";
if (! $db->db_query($qry))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'Spalte lvexport wurde in hr.tbl_gehaltstyp neu erstellt<br>';
$qryatz = "
UPDATE
hr.tbl_gehaltstyp
SET
lvexport = false
WHERE
gehaltstyp_kurzbz = 'lohnausgleichatz';
";
if (! $db->db_query($qryatz))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'Spalte lvexport wurde in hr.tbl_gehaltstyp fuer gehaltstyp lohnausgleichatz auf false gesetzt<br>';
}
}
if ($result = $db->db_query("SELECT * FROM information_schema.columns WHERE column_name='lvexport_sum' AND table_name='tbl_gehaltstyp' AND table_schema='hr'"))
{
if ($db->db_num_rows($result) == 0)
{
$qry = "
ALTER TABLE
hr.tbl_gehaltstyp
ADD COLUMN
lvexport_sum VARCHAR(255) default null;
";
if (! $db->db_query($qry))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'Spalte lvexport_sum wurde in hr.tbl_gehaltstyp neu erstellt<br>';
$qrysortorder = "
UPDATE
hr.tbl_gehaltstyp
SET
sort = sort + 1
WHERE
sort > 3;
";
if (! $db->db_query($qrysortorder))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'Spalte sort wurde in hr.tbl_gehaltstyp fuer sort > 3 erhoeht<br>';
$qryzulageallin = "
INSERT INTO
hr.tbl_gehaltstyp
(gehaltstyp_kurzbz, bezeichnung, valorisierung, sort,aktiv, lvexport)
VALUES
('zulage_allin', 'Zulage (Allin)', true, 4, true, true);
";
if (! $db->db_query($qryzulageallin))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'gehaltstyp zulage_allin wurde in hr.tbl_gehaltstyp hinzugefuegt<br>';
$qrysetsum = "
UPDATE
hr.tbl_gehaltstyp
SET
lvexport_sum = 'GRUNDGEHALT'
WHERE
gehaltstyp_kurzbz IN ('grundgehalt', 'zulage_allin');
";
if (! $db->db_query($qrysetsum))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'Spalte lvexprt_sum wurde in hr.tbl_gehaltstyp fuer grundgehalt '
. 'und zulage_allin auf GRUNDGEHALT gesetzt<br>';
$qrysetzulageallin = "
WITH gbsallin AS (
SELECT
*
FROM
hr.tbl_gehaltsbestandteil g
JOIN
hr.tbl_vertragsbestandteil_freitext f ON g.vertragsbestandteil_id = f.vertragsbestandteil_id
WHERE
f.freitexttyp_kurzbz = 'allin'
AND
g.gehaltstyp_kurzbz <> 'zulage_allin'
)
UPDATE
hr.tbl_gehaltsbestandteil
SET
gehaltstyp_kurzbz = 'zulage_allin'
WHERE
gehaltsbestandteil_id IN (SELECT gehaltsbestandteil_id FROM gbsallin);
";
if (! $db->db_query($qrysetzulageallin))
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
else
echo 'gehaltstyp_kurzbz wurde bei gehaltsbestandteilen an allin '
. 'freitext vertragsbestandteilen auf zulage_allin gesetzt<br>';
}
}
@@ -0,0 +1,13 @@
<?php
// Added Buchungstyp "StudiengebuehrErhoeht"
if ($result = @$db->db_query("SELECT 1 FROM public.tbl_buchungstyp WHERE buchungstyp_kurzbz = 'KautionDrittStaat';"))
{
if ($db->db_num_rows($result) == 0)
{
$qry = "INSERT INTO public.tbl_buchungstyp (buchungstyp_kurzbz, beschreibung, standardtext, standardbetrag) VALUES ('KautionDrittStaat', 'Kaution', 'Deposit for application, third countries', '-250');";
if (!$db->db_query($qry))
echo '<strong>public.tbl_buchungstyp '.$db->db_last_error().'</strong><br>';
else
echo ' public.tbl_buchungstyp: Added buchungstyp "KautionDrittStaat" <br>';
}
}
+13
View File
@@ -78,3 +78,16 @@ if ($result = $db->db_query("SELECT * FROM pg_class WHERE relname='idx_tbl_lehrv
}
}
if(!@$db->db_query("SELECT lehrform_kurzbz FROM lehre.tbl_lehrveranstaltung_faktor LIMIT 1"))
{
$qry = "ALTER TABLE lehre.tbl_lehrveranstaltung_faktor ADD COLUMN lehrform_kurzbz varchar(8);
ALTER TABLE lehre.tbl_lehrveranstaltung_faktor ADD CONSTRAINT fk_lehrveranstaltung_faktor_lehrform_kurzbz FOREIGN KEY (lehrform_kurzbz) REFERENCES lehre.tbl_lehrform (lehrform_kurzbz) ON DELETE CASCADE ON UPDATE CASCADE;
ALTER TABLE lehre.tbl_lehrveranstaltung_faktor DROP CONSTRAINT fk_lehrveranstaltung_faktor_lehrveranstaltung_id;
ALTER TABLE lehre.tbl_lehrveranstaltung_faktor ADD CONSTRAINT fk_lehrveranstaltung_faktor_lehrveranstaltung_id FOREIGN KEY (lehrveranstaltung_id) REFERENCES lehre.tbl_lehrveranstaltung (lehrveranstaltung_id) ON DELETE CASCADE ON UPDATE CASCADE;
";
if(!$db->db_query($qry))
echo '<strong>lehre.tbl_lehrveranstaltung_faktor '.$db->db_last_error().'</strong><br>';
else
echo '<br>Spalte lehrform_kurzbz zu Tabelle lehre.tbl_lehrveranstaltung_faktor hinzugefügt';
}
@@ -0,0 +1,16 @@
<?php
if (! defined('DB_NAME')) exit('No direct script access allowed');
// system.tbl_berechtigung: add berechtigung addons/reports:begrenzt
if($result = $db->db_query("SELECT 1 FROM system.tbl_berechtigung WHERE berechtigung_kurzbz='addon/reports:begrenzt'"))
{
if($db->db_num_rows($result)==0)
{
$qry = "INSERT INTO system.tbl_berechtigung(berechtigung_kurzbz, beschreibung) VALUES('addon/reports:begrenzt', 'Reports nur über Direktlink aufrufbar');";
if(!$db->db_query($qry))
echo '<strong>Berechtigung: '.$db->db_last_error().'</strong><br>';
else
echo '<br>Neue Berechtigung addon/reports:begrenzt zu system.tbl_berechtigung hinzugefügt';
}
}
@@ -0,0 +1,41 @@
<?php
/* Copyright (C) 2017 fhcomplete.org
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
*
* Authors: Harald Bamberger <harald.bamberger@technikum-wien.at>,
*
* Beschreibung:
* Permission basis/verwaltet_oe
*/
if (! defined('DB_NAME')) exit('No direct script access allowed');
// Add permission: basis/gehaelter
if($result = @$db->db_query("SELECT 1 FROM system.tbl_berechtigung WHERE berechtigung_kurzbz = 'basis/verwaltet_oe';"))
{
if($db->db_num_rows($result) == 0)
{
$qry = "INSERT INTO system.tbl_berechtigung(berechtigung_kurzbz, beschreibung) VALUES('basis/verwaltet_oe', 'Rechteinhaberin hat etwas mit der Verwaltung der OE zu tun.');";
if(!$db->db_query($qry))
{
echo '<strong>system.tbl_berechtigung '.$db->db_last_error().'</strong><br>';
}
else
{
echo 'system.tbl_berechtigung: Added permission "basis/verwaltet_oe"<br>';
}
}
}
+16
View File
@@ -324,6 +324,22 @@ $fehlerArr = array(
'fehlertext' => 'Es sind mehrere oder keine Zustelladressen eingetragen',
'fehlertyp_kurzbz' => 'error',
'app' => 'core'
),
array(
'fehlercode' => 'CORE_PERSON_0005',
'fehler_kurzbz' => 'geburtsnationFehlt',
'fehlercode_extern' => null,
'fehlertext' => 'Geburtsnation nicht vorhanden',
'fehlertyp_kurzbz' => 'error',
'app' => 'core'
),
array(
'fehlercode' => 'CORE_PERSON_0006',
'fehler_kurzbz' => 'uhstatPersonkennungFehltCore',
'fehlercode_extern' => null,
'fehlertext' => 'Personkennung fehlt (vBpk AS, vBpk BF oder Ersatzkennzeichen fehlt)',
'fehlertyp_kurzbz' => 'error',
'app' => 'core'
)
/** Plausichecks end **/
);
+4593 -16
View File
File diff suppressed because it is too large Load Diff