From a51a4c48f149cb82a5aa0ff455966c853f9ae682 Mon Sep 17 00:00:00 2001 From: liugang Date: Fri, 18 May 2018 14:27:01 +0800 Subject: [PATCH] * Remove $mode == 'table'. --- module/bug/model.php | 3 ++- module/datatable/view/ajaxcustom.html.php | 3 ++- module/doc/view/index.html.php | 2 +- module/task/model.php | 3 ++- module/testcase/model.php | 3 ++- module/testtask/model.php | 14 +++++++------- 6 files changed, 16 insertions(+), 12 deletions(-) diff --git a/module/bug/model.php b/module/bug/model.php index c59d96aa25..b5142f775c 100644 --- a/module/bug/model.php +++ b/module/bug/model.php @@ -2421,7 +2421,8 @@ class bugModel extends model switch($id) { case 'id': - if($mode == 'table' && $canBatchAction) + //if($mode == 'table' && $canBatchAction) + if($canBatchAction) { echo html::checkbox('bugIDList', array($bug->id => sprintf('%03d', $bug->id))); } diff --git a/module/datatable/view/ajaxcustom.html.php b/module/datatable/view/ajaxcustom.html.php index 4533254625..828b66e450 100644 --- a/module/datatable/view/ajaxcustom.html.php +++ b/module/datatable/view/ajaxcustom.html.php @@ -194,7 +194,8 @@ $(function() return sets; }).get(); - window.saveDatatableConfig('', setting, true, $('#global1').prop('checked') ? 1 : 0); + //window.saveDatatableConfig('', setting, true, $('#global1').prop('checked') ? 1 : 0); + window.saveDatatableConfig('', setting, true, $('#global1').prop('checked') ? 1 : 0); }); $('#resetBtn').on("click", function() diff --git a/module/doc/view/index.html.php b/module/doc/view/index.html.php index ff6ed7878b..b5bef4de04 100644 --- a/module/doc/view/index.html.php +++ b/module/doc/view/index.html.php @@ -170,7 +170,7 @@ - + id}");?>"> title;?> addedBy);?> editedDate) ? formatTime($doc->editedDate, 'm-d H:i') : formatTime($doc->addedDate, 'm-d H:i');?> diff --git a/module/task/model.php b/module/task/model.php index f382698a27..da7c337b14 100644 --- a/module/task/model.php +++ b/module/task/model.php @@ -2258,7 +2258,8 @@ class taskModel extends model switch($id) { case 'id': - if($mode == 'table' && $canBatchAction) + //if($mode == 'table' && $canBatchAction) + if($canBatchAction) { echo html::checkbox('taskIDList', array($task->id => sprintf('%03d', $task->id))); } diff --git a/module/testcase/model.php b/module/testcase/model.php index 71882ddbd1..821d10189d 100644 --- a/module/testcase/model.php +++ b/module/testcase/model.php @@ -1307,7 +1307,8 @@ class testcaseModel extends model switch($id) { case 'id': - echo $mode == 'table' ? html::checkbox('caseIDList', array($case->id => sprintf('%03d', $case->id))) : sprintf('%03d', $case->id); + //echo $mode == 'table' ? html::checkbox('caseIDList', array($case->id => sprintf('%03d', $case->id))) : sprintf('%03d', $case->id); + echo html::checkbox('caseIDList', array($case->id => sprintf('%03d', $case->id))); break; case 'pri': echo ""; diff --git a/module/testtask/model.php b/module/testtask/model.php index d46cdbc256..b5e62805e6 100644 --- a/module/testtask/model.php +++ b/module/testtask/model.php @@ -1156,14 +1156,14 @@ class testtaskModel extends model switch ($id) { case 'id': - if($mode == 'table') - { + //if($mode == 'table') + //{ echo html::checkbox('caseIDList', array($run->case => sprintf('%03d', $run->case))); - } - else - { - echo $canView ? html::a($caseLink, sprintf('%03d', $run->case)) : sprintf('%03d', $run->case); - } + //} + //else + //{ + // echo $canView ? html::a($caseLink, sprintf('%03d', $run->case)) : sprintf('%03d', $run->case); + //} break; case 'pri': echo "";