From 5c7aeec9b73f6faeeb33e030ec7e5ba9ca29fdda Mon Sep 17 00:00:00 2001 From: liumengyi Date: Mon, 4 Mar 2024 16:24:07 +0800 Subject: [PATCH] * Fix bug #46517, append module name before title. --- module/caselib/js/browse.ui.js | 4 +++- module/caselib/ui/browse.html.php | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/module/caselib/js/browse.ui.js b/module/caselib/js/browse.ui.js index adfb78bc20..857090f03e 100644 --- a/module/caselib/js/browse.ui.js +++ b/module/caselib/js/browse.ui.js @@ -41,8 +41,10 @@ window.onRenderCell = function(result, {row, col}) { if(col.name == 'title') { - const data = row.data; + const data = row.data; + const module = this.options.customData.modules[data.module]; if(data.color) result[0].props.style = 'color: ' + data.color; + if(module) result.unshift({html: '' + module + ''}); // 添加模块标签 } } diff --git a/module/caselib/ui/browse.html.php b/module/caselib/ui/browse.html.php index 675ffd1d8c..38bfb3f361 100644 --- a/module/caselib/ui/browse.html.php +++ b/module/caselib/ui/browse.html.php @@ -150,6 +150,7 @@ dtable ( set::cols($cols), set::data(array_values($tableData)), + set::customData(array('modules' => $modulePairs)), set::onRenderCell(jsRaw('window.onRenderCell')), set::userMap($users), set::checkable($canBatchAction),