import Mailverteiler from "./ProfilComponents/Mailverteiler.js"; import ProfilEmails from "./ProfilComponents/ProfilEmails.js"; import RoleInformation from "./ProfilComponents/RoleInformation.js"; import ProfilInformation from "./ProfilComponents/ProfilInformation.js"; import QuickLinks from "./ProfilComponents/QuickLinks.js"; export default { components: { Mailverteiler, ProfilEmails, RoleInformation, ProfilInformation, QuickLinks, }, props: ["data", "permissions"], data() { return {}; }, provide() { return { studiengang_kz: Vue.computed({ get: () => this.data.studiengang_kz, }), }; }, computed: { fotoStatus() { return this.data?.fotoStatus ?? null; }, profilInformation() { if (!this.data) { return {}; } return { Vorname: this.data.vorname, Nachname: this.data.nachname, Username: this.data.username, Anrede: this.data.anrede, Titel: this.data.titel, Postnomen: this.data.postnomen, foto_sperre: this.data.foto_sperre, foto: this.data.foto, }; }, personEmails() { return this.data?.emails ? this.data.emails : []; }, roleInformation() { if (!this.data) { return {}; } return { geburtsdatum: { label: `${this.$p.t("profil", "Geburtsdatum")}`, value: this.data.gebdatum, }, geburtsort: { label: `${this.$p.t("profil", "Geburtsort")}`, value: this.data.gebort, }, personenkennzeichen: { label: `${this.$p.t("person", "personenkennzeichen")}`, value: this.data.personenkennzeichen, }, matrikelnummer: { label: this.$p.t('person/matrikelnummer'), value: this.data.matrikelnummer }, studiengang: { label: `${this.$p.t("lehre", "studiengang")}`, value: this.data.studiengang, }, semester: { label: `${this.$p.t("lehre", "semester")}`, value: this.data.semester, }, verband: { label: `${this.$p.t("lehre", "lehrverband")}`, value: this.data.verband, }, gruppe: { label: `${this.$p.t("lehre", "gruppe")}`, value: this.data.gruppe.trim(), }, }; }, quickLinks() { let quickLinks = []; if (this.$props.permissions && this.$props.permissions["basis/other_lv_plan"]) { quickLinks.push({ icon: "fa-calendar-days", phrase: "lehre/stundenplan", action: () => { this.$router.push({ name: "OtherLvPlan", params: { otherUid: this.$props.data.username }, }); }, }); } return quickLinks; }, }, template: /*html*/ `
`, };