diff --git a/application/config/routes.php b/application/config/routes.php index 32f938f8b..8441f56aa 100644 --- a/application/config/routes.php +++ b/application/config/routes.php @@ -71,7 +71,7 @@ $route['Cis/StgOrgLvPlan/.*'] = 'Cis/StgOrgLvPlan/index/$1'; //Route for Zeitsperrenma $route['Cis/Zeitsperrenma/.*'] = 'Cis/Zeitsperrenma/index/$1'; //Route für Zeitsperren -//$route['Cis/Zeitsperren/.*'] = 'Cis/Zeitsperren/index/$1'; +$route['Cis/Zeitsperren/.*'] = 'Cis/Zeitsperren/index/$1'; $route['Abgabetool/Assistenz'] = 'Cis/Abgabetool/Assistenz'; $route['Abgabetool/Assistenz/(:any)'] = 'Cis/Abgabetool/Assistenz/$1'; diff --git a/public/js/apps/Cis/Cis.js b/public/js/apps/Cis/Cis.js index 0f076f552..8efd93821 100644 --- a/public/js/apps/Cis/Cis.js +++ b/public/js/apps/Cis/Cis.js @@ -4,7 +4,7 @@ import Theme from '../../plugins/Theme.js'; import contrast from '../../directives/contrast.js'; import {setScrollbarWidth} from "../../helpers/CssVarCalcHelpers.js"; import LvPlan from "../../components/Cis/LvPlan/Lehrveranstaltung.js"; -import MyLvPlan from "../../components/Cis/LvPlan/Personal.js"; +import MyLvPlan from "../../components/Cis/LvPlan/MyLvPlan.js"; import MylvStudent from "../../components/Cis/Mylv/Student.js"; import Profil from "../../components/Cis/Profil/Profil.js"; import Raumsuche from "../../components/Cis/Raumsuche/Raumsuche.js"; diff --git a/public/js/components/Cis/Zeitsperren/Zeitsperren.js b/public/js/components/Cis/Zeitsperren/Zeitsperren.js index 5cbd66b98..ef383f537 100644 --- a/public/js/components/Cis/Zeitsperren/Zeitsperren.js +++ b/public/js/components/Cis/Zeitsperren/Zeitsperren.js @@ -219,6 +219,39 @@ export default { }); return diff; }, + async updateTableTranslations() { + await this.$p.loadCategory(['global', 'person', 'zeitsperren', 'ui', 'abschlusspruefung']); + + let cm = this.$refs.table.tabulator.columnManager; + + cm.getColumnByField('bezeichnung').component.updateDefinition({ + title: this.$capitalize(this.$p.t('person', 'grund')) + }); + cm.getColumnByField('beschreibung').component.updateDefinition({ + title: this.$capitalize(this.$p.t('global', 'bezeichnung')) + }); + cm.getColumnByField('vondatum').component.updateDefinition({ + title: this.$capitalize(this.$p.t('ui', 'von')) + }); + cm.getColumnByField('bisdatum').component.updateDefinition({ + title: this.$capitalize(this.$p.t('global', 'bis')) + }); + cm.getColumnByField('vonstunde').component.updateDefinition({ + title: this.$capitalize(this.$p.t('zeitsperren', 'stunde_von')) + }); + cm.getColumnByField('bisstunde').component.updateDefinition({ + title: this.$capitalize(this.$p.t('zeitsperren', 'stunde_bis')) + }); + cm.getColumnByField('vertretung').component.updateDefinition({ + title: this.$capitalize(this.$p.t('person', 'vertretung')) + }); + cm.getColumnByField('erreichbarkeit_beschreibung').component.updateDefinition({ + title: this.$capitalize(this.$p.t('person', 'erreichbarkeit')) + }); + cm.getColumnByField('freigabeamum').component.updateDefinition({ + title: this.$capitalize(this.$p.t('abschlusspruefung', 'freigabe')) + }); + } }, watch: { selectedVertretung(newVal) { @@ -234,6 +267,12 @@ export default { } else { this.zeitsperreData.bezeichnung = ''; } + }, + '$p.user_language.value'(n, o) { + if (n !== o && o !== undefined && this.$refs.table.tableBuilt) { + this.updateTableTranslations(); + this.reload(); + } } }, created() { @@ -340,43 +379,7 @@ export default { { event: 'tableBuilt', handler: async() => { - await this.$p.loadCategory(['global', 'person', 'zeitsperren', 'ui', 'abschlusspruefung']); - - let cm = this.$refs.table.tabulator.columnManager; - - cm.getColumnByField('bezeichnung').component.updateDefinition({ - title: this.$p.t('person', 'grund') - }); - cm.getColumnByField('beschreibung').component.updateDefinition({ - title: this.$p.t('global', 'bezeichnung') - }); - cm.getColumnByField('vondatum').component.updateDefinition({ - title: this.$p.t('ui', 'von') - }); - cm.getColumnByField('bisdatum').component.updateDefinition({ - title: this.$p.t('global', 'bis') - }); - cm.getColumnByField('vonstunde').component.updateDefinition({ - title: this.$p.t('zeitsperren', 'stunde_von') - }); - cm.getColumnByField('bisstunde').component.updateDefinition({ - title: this.$p.t('zeitsperren', 'stunde_bis') - }); - cm.getColumnByField('vertretung').component.updateDefinition({ - title: this.$p.t('person', 'vertretung') - }); - - cm.getColumnByField('erreichbarkeit_beschreibung').component.updateDefinition({ - title: this.$p.t('person', 'erreichbarkeit') - }); - cm.getColumnByField('freigabeamum').component.updateDefinition({ - title: this.$p.t('abschlusspruefung', 'freigabe') - }); - - /* cm.getColumnByField('actions').component.updateDefinition({ - title: this.$p.t('global', 'aktionen') - });*/ - + await this.updateTableTranslations(); } } ]; @@ -406,7 +409,7 @@ export default { }, template: /* html */`