From 9fa7166c84ead91f06a520b7c8de05d688800234 Mon Sep 17 00:00:00 2001 From: ma0068 Date: Fri, 17 Oct 2025 12:33:22 +0200 Subject: [PATCH] added download to StudentList --- .../components/Stv/Studentenverwaltung/List.js | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/public/js/components/Stv/Studentenverwaltung/List.js b/public/js/components/Stv/Studentenverwaltung/List.js index 67cada523..a5331a7c4 100644 --- a/public/js/components/Stv/Studentenverwaltung/List.js +++ b/public/js/components/Stv/Studentenverwaltung/List.js @@ -307,6 +307,23 @@ export default { + ' | ' + this.$p.t('global/gesamt') + ': ' + (this.count || 0) + ''; + }, + downloadConfig() { + return { + csv: { + formatter: 'csv', + file: this.fileString, + options: { + delimiter: ';', + bom: true, + } + } + }; + }, + fileString() { + let today = new Date().toLocaleDateString('en-GB') + .replace(/\//g, '_'); + return "StudentList_" + today + ".csv"; } }, // TODO(chris): focusin, focusout, keydown and tabindex should be in the filter component @@ -322,6 +339,7 @@ export default { table-only :side-menu="false" reload + :download="downloadConfig" ` + /* TODO(chris): Ausgeblendet für Testing new-btn-show */`