From 1817757745ec564b84f9ebf5423335ef2785d7f8 Mon Sep 17 00:00:00 2001 From: Simon Gschnell Date: Mon, 27 Nov 2023 12:01:04 +0100 Subject: [PATCH] adds the @ to the emails and changes the layout of the information displayed on the profile page --- application/controllers/Cis/Profil.php | 20 +++++-- public/js/components/Cis/Profil/Profil.js | 63 +++++++++++++++-------- 2 files changed, 58 insertions(+), 25 deletions(-) diff --git a/application/controllers/Cis/Profil.php b/application/controllers/Cis/Profil.php index cbbc84145..048c25959 100644 --- a/application/controllers/Cis/Profil.php +++ b/application/controllers/Cis/Profil.php @@ -158,17 +158,31 @@ class Profil extends Auth_Controller $mitarbeiter_res = hasData($mitarbeiter_res)? getData($mitarbeiter_res)[0] : null; } + // collection for the first collumn + $first_column = new stdClass(); + $first_column->username = getAuthUID(); + $first_column->anrede = $person_res->anrede; + $first_column->titelpre = $person_res->titelpre; + $first_column->titelpost = $person_res->titelpost; + $first_column->vorname = $person_res->vorname; + $first_column->nachname = $person_res->nachname; + + $res = new stdClass(); $res->username = getAuthUID(); + + //? Person Info $res->foto = $person_res->foto; $res->foto_sperre = $person_res->foto_sperre; + $res->anrede = $person_res->anrede; $res->titelpre = $person_res->titelpre; $res->titelpost = $person_res->titelpost; $res->vorname = $person_res->vorname; $res->nachname = $person_res->nachname; //$res->postnomen = $person_res->postnomen; //!POSTNOMEN? + $res->gebdatum = $person_res->gebdatum; $res->gebort = $person_res->gebort; //? Mitarbeiter Info @@ -177,10 +191,10 @@ class Profil extends Auth_Controller //? Email Info $intern_email = array(); $intern_email+=array("type" => "intern"); - $intern_email+=array("email"=> getAuthUID() . DOMAIN); + $intern_email+=array("email"=> getAuthUID() . "@" . DOMAIN); $extern_email=array(); - $extern_email+=array("type" => "extern"); - $extern_email+=array("email" => $benutzer_res->alias . DOMAIN); + $extern_email+=array("type" => "alias"); + $extern_email+=array("email" => $benutzer_res->alias . "@" . DOMAIN); $res->emails = array($intern_email,$extern_email); //? Adresse Info $res->adressen = $adresse_res; diff --git a/public/js/components/Cis/Profil/Profil.js b/public/js/components/Cis/Profil/Profil.js index 7361f8026..260d92b02 100644 --- a/public/js/components/Cis/Profil/Profil.js +++ b/public/js/components/Cis/Profil/Profil.js @@ -109,26 +109,33 @@ export default { } return "data:image/jpeg;base64,"+(this.person_info ? this.person_info.foto : ""); }, - first_col(){ + personData(){ if(!this.person_info){ return {}; } //! postnomen is still missing return { - Username:this.uid, + Allgemein: { + Username:this.uid, Anrede:this.person_info.anrede, Titel:(this.person_info.titelpre&&this.person_info.titelpost)?this.person_info.titelpre.concat(this.person_info.titelpost):"null", Vorname:this.person_info.vorname, Nachname:this.person_info.nachname, Postnomen:null, + }, + GeburtsDaten:{ Geburtsdatum:this.person_info.gebdatum, Geburtsort: this.person_info.gebort, - Adresse: this.person_info.adressen, + }, + Adressen: this.person_info.adressen, + SpecialInformation: { Kurzzeichen: this.person_info.kurzbz, Telefon: this.person_info.telefonklappe, + }, }; }, - second_col(){ + //? this computed conains all the information that is used for the second column that displays the information of the person + kontaktInfo(){ if(!this.person_info){ return {}; } @@ -169,6 +176,7 @@ export default { }, template: ` +
@@ -180,7 +188,7 @@ export default {
-
+
@@ -197,37 +205,48 @@ export default {
- -
    -
  1. +

    Mitarbeiter

    +

    Student

    + +
    + +
    {{element.strasse}} ({{element.adr_typ}})
    {{ element.plz}} {{element.ort}}
    +
    {{bez}}: {{val}}
    + +
    -

    {{element.strasse +" "+element.adr_typ+" " + element.plz+" "+element.ort}}

    - -

    {{bezeichnung +": " +wert}}

    -
  2. -
    -
  1. +
  2. -
    -

    FH-Ausweis Status

    -

    {{"Der FH Ausweis ist am "+ wert+ " ausgegeben worden."}}

    +
    +

    FH-Ausweis Status

    +

    {{"Der FH Ausweis ist am "+ wert+ " ausgegeben worden."}}

    + + + +
    +

    eMail

    +

    {{email.type}}: {{email.email}}

    +
    -
    -

    Private Kontakte

    - - {{element.kontakttyp + " " + element.kontakt+" " }} +
    +

    Private Kontakte

    +
    +
    {{element.kontakttyp + " " + element.kontakt+" " }}
    +
    {{element?.anmerkung}}
    +
    - +
    +