added new contact type email unverifiziert and adresse type meldeadresse (mainly for electronic onboarding)

This commit is contained in:
Alexei Karpenko
2024-10-13 13:32:15 +02:00
parent 469867e98c
commit bf1bc8d1a9
2 changed files with 31 additions and 0 deletions
+1
View File
@@ -58,6 +58,7 @@ require_once('dbupdate_3.4/17513_Entwicklungsteam.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/40314_electronic_onboarding_anbindung_ida.php');
// *** Pruefung und hinzufuegen der neuen Attribute und Tabellen
echo '<H2>Pruefe Tabellen und Attribute!</H2>';
@@ -0,0 +1,30 @@
<?php
if (! defined('DB_NAME')) exit('No direct script access allowed');
// public.tbl_kontakttyp: add type email unverified
if($result = $db->db_query("SELECT 1 FROM public.tbl_kontakttyp WHERE kontakttyp='email_unverifiziert'"))
{
if($db->db_num_rows($result)==0)
{
$qry = "INSERT INTO public.tbl_kontakttyp(kontakttyp, beschreibung, bezeichnung_mehrsprachig) VALUES('email_unverifiziert', 'Unverifizierte E-Mail', '{\"Unverifizierte E-Mail\", \"Unverified email\"}');";
if(!$db->db_query($qry))
echo '<strong>Kontakttyp: '.$db->db_last_error().'</strong><br>';
else
echo '<br>Neuen Kontakttyp E-Mail unverifiziert in public.tbl_kontakttyp hinzugefügt';
}
}
// public.tbl_adressentyp: add type Meldeadresse
if($result = $db->db_query("SELECT 1 FROM public.tbl_adressentyp WHERE adressentyp_kurzbz='m'"))
{
if($db->db_num_rows($result)==0)
{
$qry = "INSERT INTO public.tbl_adressentyp(adressentyp_kurzbz, bezeichnung, bezeichnung_mehrsprachig, sort) VALUES('m', 'Meldeadresse', '{\"Meldeadresse\", \"Registered adress\"}', 6);";
if(!$db->db_query($qry))
echo '<strong>Adressentyp: '.$db->db_last_error().'</strong><br>';
else
echo '<br>Neue Adressentyp Meldeadresse in public.tbl_adressentyp hinzugefügt';
}
}