From 3136cf354a06400f85da2ede5c5a7b0036e47c55 Mon Sep 17 00:00:00 2001 From: ma0048 Date: Thu, 27 Jan 2022 11:00:26 +0100 Subject: [PATCH 1/2] alle eingetragenen adressen nur beim mitarbeiter anzeigen --- cis/private/profile/index.php | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/cis/private/profile/index.php b/cis/private/profile/index.php index 1f1330839..d7a2e76aa 100644 --- a/cis/private/profile/index.php +++ b/cis/private/profile/index.php @@ -293,9 +293,35 @@ if (!$ansicht) $adresse = new adresse(); $adresse->load_pers($user->person_id); - foreach($adresse->result as $a) + if ($type === 'mitarbeiter') { - echo $a->strasse . " (" . $a->bezeichnung_mehrsprachig[$sprache] .") " . "
".$a->plz." ".$a->ort."

"; + foreach ($adresse->result as $a) + { + echo $a->strasse . " (" . $a->bezeichnung_mehrsprachig[$sprache] . ") " . "
" . $a->plz . " " . $a->ort . "

"; + } + } + else + { + function sortAdresse($a , $b) + { + if ($a->typ === $b->typ) + return 0; + + return ($a->typ < $b->typ) ? -1 : 1; + } + usort($adresse->result, "sortAdresse"); + + foreach($adresse->result as $a) + { + if ($a->zustelladresse) + { + if ($a->bezeichnung_mehrsprachig[$sprache] !== NULL) + { + echo "".$a->bezeichnung_mehrsprachig[$sprache].":
"; + echo $a->strasse."
".$a->plz." ".$a->ort."

"; + } + } + } } } From 4ccc659dd9d792f44461ae684467e8290496c200 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20=C3=96sterreicher?= Date: Tue, 1 Feb 2022 17:13:16 +0100 Subject: [PATCH 2/2] =?UTF-8?q?Anzeige=20f=C3=BCr=20Hauptberuf=20korrigier?= =?UTF-8?q?t?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cis/private/profile/index.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cis/private/profile/index.php b/cis/private/profile/index.php index d7a2e76aa..512e1fd64 100644 --- a/cis/private/profile/index.php +++ b/cis/private/profile/index.php @@ -274,7 +274,7 @@ if (!$ansicht) if (!$ansicht) { - if ($is_employee) + if ($type === 'mitarbeiter') { $verwendung = new bisverwendung(); if($verwendung->getLastVerwendung($uid))