mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-06-01 12:19:28 +00:00
add config STV_TAGS_ENABLED and use it to enable or disable tags in StudVw
This commit is contained in:
@@ -48,6 +48,7 @@ $configArray = [
|
|||||||
'allowUebernahmePunkte' => !defined('FAS_REIHUNGSTEST_PUNKTEUEBERNAHME') ? true : FAS_REIHUNGSTEST_PUNKTEUEBERNAHME,
|
'allowUebernahmePunkte' => !defined('FAS_REIHUNGSTEST_PUNKTEUEBERNAHME') ? true : FAS_REIHUNGSTEST_PUNKTEUEBERNAHME,
|
||||||
'useReihungstestPunkte' => !defined('FAS_REIHUNGSTEST_PUNKTE') ? true : FAS_REIHUNGSTEST_PUNKTE,
|
'useReihungstestPunkte' => !defined('FAS_REIHUNGSTEST_PUNKTE') ? true : FAS_REIHUNGSTEST_PUNKTE,
|
||||||
'hasExcludedAreas' => defined('FAS_REIHUNGSTEST_EXCLUDE_GEBIETE') && !empty(FAS_REIHUNGSTEST_EXCLUDE_GEBIETE),
|
'hasExcludedAreas' => defined('FAS_REIHUNGSTEST_EXCLUDE_GEBIETE') && !empty(FAS_REIHUNGSTEST_EXCLUDE_GEBIETE),
|
||||||
|
'stvTagsEnabled' => defined('STV_TAGS_ENABLED') ? STV_TAGS_ENABLED : false,
|
||||||
];
|
];
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|||||||
@@ -371,4 +371,6 @@ define('STATUS_VORRUECKEN_ANZEIGEN', true);
|
|||||||
//externe Ueberwachung im Testtool erlauben
|
//externe Ueberwachung im Testtool erlauben
|
||||||
define('TESTTOOL_EXTERNE_UEBERWACHUNG_ALLOWED', false);
|
define('TESTTOOL_EXTERNE_UEBERWACHUNG_ALLOWED', false);
|
||||||
|
|
||||||
|
//enable tags in StudVW
|
||||||
|
define('STV_TAGS_ENABLED', false);
|
||||||
?>
|
?>
|
||||||
|
|||||||
@@ -85,6 +85,7 @@ export default {
|
|||||||
configAllowUebernahmePunkte: this.config.allowUebernahmePunkte,
|
configAllowUebernahmePunkte: this.config.allowUebernahmePunkte,
|
||||||
configUseReihungstestPunkte: this.config.useReihungstestPunkte,
|
configUseReihungstestPunkte: this.config.useReihungstestPunkte,
|
||||||
configHasExcludedAreas: this.config.hasExcludedAreas,
|
configHasExcludedAreas: this.config.hasExcludedAreas,
|
||||||
|
configStvTagsEnabled: this.config.stvTagsEnabled,
|
||||||
appConfig: Vue.computed(() => this.appconfig),
|
appConfig: Vue.computed(() => this.appconfig),
|
||||||
hasZGVBakkPermission: this.permissions['student/editBakkZgv'],
|
hasZGVBakkPermission: this.permissions['student/editBakkZgv'],
|
||||||
hasZGVMasterPermission: this.permissions['student/editMakkZgv'],
|
hasZGVMasterPermission: this.permissions['student/editMakkZgv'],
|
||||||
|
|||||||
@@ -35,7 +35,11 @@ export default {
|
|||||||
currentSemester: {
|
currentSemester: {
|
||||||
from: 'currentSemester',
|
from: 'currentSemester',
|
||||||
required: true
|
required: true
|
||||||
}
|
},
|
||||||
|
tagsEnabled: {
|
||||||
|
from: 'configStvTagsEnabled',
|
||||||
|
default: false
|
||||||
|
},
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
selected: Array,
|
selected: Array,
|
||||||
@@ -65,16 +69,6 @@ export default {
|
|||||||
columns:[
|
columns:[
|
||||||
{title:"UID", field:"uid", headerFilter: true},
|
{title:"UID", field:"uid", headerFilter: true},
|
||||||
{title:"TitelPre", field:"titelpre", headerFilter: "list", headerFilterParams: {valuesLookup:true, listOnEmpty:true, autocomplete:true, sort:"asc"}},
|
{title:"TitelPre", field:"titelpre", headerFilter: "list", headerFilterParams: {valuesLookup:true, listOnEmpty:true, autocomplete:true, sort:"asc"}},
|
||||||
{
|
|
||||||
title: 'Tags',
|
|
||||||
field: 'tags',
|
|
||||||
tooltip: false,
|
|
||||||
headerFilter: "input",
|
|
||||||
headerFilterFunc: tagHeaderFilter,
|
|
||||||
headerFilterFuncParams: {field: 'tags'},
|
|
||||||
formatter: (cell) => tagFormatter(cell, this.$refs.tagComponent),
|
|
||||||
width: 150,
|
|
||||||
},
|
|
||||||
{title:"Nachname", field:"nachname", headerFilter: true},
|
{title:"Nachname", field:"nachname", headerFilter: true},
|
||||||
{title:"Vorname", field:"vorname", headerFilter: true},
|
{title:"Vorname", field:"vorname", headerFilter: true},
|
||||||
{title:"Wahlname", field:"wahlname", visible:false, headerFilter: true},
|
{title:"Wahlname", field:"wahlname", visible:false, headerFilter: true},
|
||||||
@@ -279,6 +273,21 @@ export default {
|
|||||||
return "StudentList_" + today + ".csv";
|
return "StudentList_" + today + ".csv";
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
created: function() {
|
||||||
|
if(this.tagsEnabled) {
|
||||||
|
const coltags = {
|
||||||
|
title: 'Tags',
|
||||||
|
field: 'tags',
|
||||||
|
tooltip: false,
|
||||||
|
headerFilter: "input",
|
||||||
|
headerFilterFunc: tagHeaderFilter,
|
||||||
|
headerFilterFuncParams: {field: 'tags'},
|
||||||
|
formatter: (cell) => tagFormatter(cell, this.$refs.tagComponent),
|
||||||
|
width: 150,
|
||||||
|
};
|
||||||
|
this.tabulatorOptions.columns.splice(2, 0, coltags);
|
||||||
|
}
|
||||||
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'$p.user_language.value'(n, o) {
|
'$p.user_language.value'(n, o) {
|
||||||
if (n !== o && o !== undefined && this.$refs.table.tableBuilt) {
|
if (n !== o && o !== undefined && this.$refs.table.tableBuilt) {
|
||||||
@@ -582,6 +591,7 @@ export default {
|
|||||||
|
|
||||||
<template #actions>
|
<template #actions>
|
||||||
<core-tag ref="tagComponent"
|
<core-tag ref="tagComponent"
|
||||||
|
v-if="tagsEnabled"
|
||||||
:endpoint="tagEndpoint"
|
:endpoint="tagEndpoint"
|
||||||
:values="selectedColumnValues"
|
:values="selectedColumnValues"
|
||||||
@added="addedTag"
|
@added="addedTag"
|
||||||
|
|||||||
Reference in New Issue
Block a user