From a8c60c105dbe72e28e4361bd54a255956821444f Mon Sep 17 00:00:00 2001 From: SimonGschnell Date: Thu, 21 Mar 2024 13:42:43 +0100 Subject: [PATCH] migrating approveLehrauftrag to tabulator5 --- .../lehre/lehrauftrag/approveLehrauftrag.php | 10 ++-- .../lehrauftrag/approveLehrauftragData.php | 2 +- public/css/Tabulator5.css | 51 +++++++++++++++++++ public/js/TableWidget.js | 4 +- .../lehre/lehrauftrag/approveLehrauftrag.js | 42 +++++++-------- 5 files changed, 78 insertions(+), 31 deletions(-) diff --git a/application/views/lehre/lehrauftrag/approveLehrauftrag.php b/application/views/lehre/lehrauftrag/approveLehrauftrag.php index 3ee1934f5..fa706f64f 100644 --- a/application/views/lehre/lehrauftrag/approveLehrauftrag.php +++ b/application/views/lehre/lehrauftrag/approveLehrauftrag.php @@ -6,7 +6,7 @@ $this->load->view( 'jquery3' => true, 'jqueryui1' => true, 'jquerycheckboxes1' => true, - 'bootstrap5' => true, + 'bootstrap3' => true, 'fontawesome4' => true, 'sbadmintemplate3' => true, 'tabulator5' => true, @@ -90,13 +90,9 @@ $this->load->view( ) ), 'customJSs' => array( - + 'public/js/bootstrapper.js', 'public/js/lehre/lehrauftrag/approveLehrauftrag.js' - ), - 'customCSSs' => array( - - 'public/css/navbar.css' - ) + ) ) ); ?> diff --git a/application/views/lehre/lehrauftrag/approveLehrauftragData.php b/application/views/lehre/lehrauftrag/approveLehrauftragData.php index 5a9323108..4900a91c4 100644 --- a/application/views/lehre/lehrauftrag/approveLehrauftragData.php +++ b/application/views/lehre/lehrauftrag/approveLehrauftragData.php @@ -404,7 +404,7 @@ $filterWidgetArray = array( vertrag_id: {visible: false}, vertrag_stunden: {visible: false}, vertrag_betrag: {visible: false}, - mitarbeiter_uid: {visible: false, headerFilter:"input"}, + mitarbeiter_uid: {visible: false, headerFilter:"input"},func_initialFilter bestellt: {align:"center", headerFilter:"input", mutator: mut_formatStringDate, tooltip: bestellt_tooltip}, erteilt: {align:"center", headerFilter:"input", mutator: mut_formatStringDate, tooltip: erteilt_tooltip}, akzeptiert: {align:"center", headerFilter:"input", mutator: mut_formatStringDate, tooltip: akzeptiert_tooltip}, diff --git a/public/css/Tabulator5.css b/public/css/Tabulator5.css index 7c7c9ed57..863ae867f 100644 --- a/public/css/Tabulator5.css +++ b/public/css/Tabulator5.css @@ -39,6 +39,57 @@ z-index: 999999; } +/* using bootstrap background classes to style the background color of tabulator rows */ +/* bg-warning */ +/* odd-rows */ +.tabulator-headers .tabulator-frozen.bg-warning, +.tabulator-row.tabulator-row-odd .tabulator-frozen.bg-warning, +.tabulator-row.tabulator-row-odd .tabulator-cell.bg-warning { + background-color: #fcf8e3; + +} +/* even-rows */ +.tabulator-headers .tabulator-frozen.bg-warning, +.tabulator-row.tabulator-row-even .tabulator-frozen.bg-warning, +.tabulator-row.tabulator-row-even .tabulator-cell.bg-warning { + background-color: #fcf8e3; + +} + +/* bg-success */ +/* odd-rows */ +.tabulator-headers .tabulator-frozen.bg-success, +.tabulator-row.tabulator-row-odd .tabulator-frozen.bg-success, +.tabulator-row.tabulator-row-odd .tabulator-cell.bg-success { + background-color: #dff0d8; + +} +/* even-rows */ +.tabulator-headers .tabulator-frozen.bg-success, +.tabulator-row.tabulator-row-even .tabulator-frozen.bg-success, +.tabulator-row.tabulator-row-even .tabulator-cell.bg-success { + background-color: #dff0d8; + +} + +/* bg-info */ +/* odd-rows */ +.tabulator-headers .tabulator-frozen.bg-info, +.tabulator-row.tabulator-row-odd .tabulator-frozen.bg-info, +.tabulator-row.tabulator-row-odd .tabulator-cell.bg-info { + background-color: #d9edf7; + +} +/* even-rows */ +.tabulator-headers .tabulator-frozen.bg-info, +.tabulator-row.tabulator-row-even .tabulator-frozen.bg-info, +.tabulator-row.tabulator-row-even .tabulator-cell.bg-info { + background-color: #d9edf7; + +} + + + .tabulator-cell .btn { padding: 0 .5rem; max-height: 22px; diff --git a/public/js/TableWidget.js b/public/js/TableWidget.js index 893a69c5f..e8ec539e2 100644 --- a/public/js/TableWidget.js +++ b/public/js/TableWidget.js @@ -931,10 +931,10 @@ function _renderTabulatorFooterHTML(tableWidgetFooterOptions){ tabulatorFooterHTML += `