mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-19 07:52:16 +00:00
add columns gehaltsbestandteil_von and gehaltsbestandteil_bis to hr.tbl_gehaltshistorie
This commit is contained in:
@@ -85,6 +85,8 @@ if ($result = $db->db_query("SELECT * FROM information_schema.tables WHERE table
|
||||
betrag bytea,
|
||||
gehaltsbestandteil_id integer,
|
||||
mitarbeiter_uid character varying(32),
|
||||
gehaltsbestandteil_von date,
|
||||
gehaltsbestandteil_bis date,
|
||||
CONSTRAINT tbl_gehaltshistorie_pk PRIMARY KEY (gehaltshistorie_id)
|
||||
);
|
||||
|
||||
@@ -570,3 +572,37 @@ if ($result = $db->db_query("SELECT * FROM hr.tbl_vertragsart WHERE vertragsart_
|
||||
echo 'Vertragsart "Dienstverhältnis zu einer anderen Bildungseinrichtung oder einem anderen Träger" erstellt.<br />';
|
||||
}
|
||||
}
|
||||
|
||||
if ($result = $db->db_query("SELECT * FROM information_schema.columns WHERE column_name='gehaltsbestandteil_von' AND table_name='tbl_gehaltshistorie' AND table_schema='hr'"))
|
||||
{
|
||||
if ($db->db_num_rows($result) == 0)
|
||||
{
|
||||
$qry = "
|
||||
ALTER TABLE
|
||||
hr.tbl_gehaltshistorie
|
||||
ADD COLUMN
|
||||
gehaltsbestandteil_von date
|
||||
";
|
||||
if (! $db->db_query($qry))
|
||||
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
|
||||
else
|
||||
echo 'Spalte gehaltsbestandteil_von wurde in hr.tbl_gehaltshistorie neu erstellt<br>';
|
||||
}
|
||||
}
|
||||
|
||||
if ($result = $db->db_query("SELECT * FROM information_schema.columns WHERE column_name='gehaltsbestandteil_bis' AND table_name='tbl_gehaltshistorie' AND table_schema='hr'"))
|
||||
{
|
||||
if ($db->db_num_rows($result) == 0)
|
||||
{
|
||||
$qry = "
|
||||
ALTER TABLE
|
||||
hr.tbl_gehaltshistorie
|
||||
ADD COLUMN
|
||||
gehaltsbestandteil_bis date
|
||||
";
|
||||
if (! $db->db_query($qry))
|
||||
echo '<strong>Vertraege: ' . $db->db_last_error() . '</strong><br>';
|
||||
else
|
||||
echo 'Spalte gehaltsbestandteil_bis wurde in hr.tbl_gehaltshistorie neu erstellt<br>';
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user