* adjust for caselib.

This commit is contained in:
wangyidong
2019-11-07 11:29:03 +08:00
parent e70fec4e04
commit edac0a4dd7
4 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -373,7 +373,7 @@ $lang->action->label->bug = 'Bug|bug|view|bugID=%s';
$lang->action->label->case = 'Case|testcase|view|caseID=%s';
$lang->action->label->testtask = 'Request|testtask|view|caseID=%s';
$lang->action->label->testsuite = 'Test Suite|testsuite|view|suiteID=%s';
$lang->action->label->caselib = 'Case Library|testsuite|libview|libID=%s';
$lang->action->label->caselib = 'Case Library|caselib|view|libID=%s';
$lang->action->label->todo = 'Todo|todo|view|todoID=%s';
$lang->action->label->doclib = 'Doc Library|doc|browse|libID=%s';
$lang->action->label->doc = 'Doc|doc|view|docID=%s';
+1 -1
View File
@@ -373,7 +373,7 @@ $lang->action->label->bug = 'Bug|bug|view|bugID=%s';
$lang->action->label->case = '用例|testcase|view|caseID=%s';
$lang->action->label->testtask = '测试单|testtask|view|caseID=%s';
$lang->action->label->testsuite = '测试套件|testsuite|view|suiteID=%s';
$lang->action->label->caselib = '用例库|testsuite|libview|libID=%s';
$lang->action->label->caselib = '用例库|caselib|view|libID=%s';
$lang->action->label->todo = '待办|todo|view|todoID=%s';
$lang->action->label->doclib = '文档库|doc|browse|libID=%s';
$lang->action->label->doc = '文档|doc|view|docID=%s';
+1 -1
View File
@@ -621,7 +621,7 @@ class testcase extends control
$moduleOptionMenu = $this->tree->getOptionMenu($productID, $viewType = 'case', $startModuleID = 0, $case->branch);
if($case->lib and $case->fromCaseID)
{
$libName = $this->loadModel('testsuite')->getById($case->lib)->name;
$libName = $this->loadModel('caselib')->getById($case->lib)->name;
$libModules = $this->tree->getOptionMenu($case->lib, 'caselib');
foreach($libModules as $moduleID => $moduleName)
{
+1 -1
View File
@@ -120,7 +120,7 @@
<?php
common::printIcon('testcase', 'edit',"caseID=$case->id", $case);
if(!$isLibCase) common::printIcon('testcase', 'create', "productID=$case->product&branch=$case->branch&moduleID=$case->module&from=testcase&param=$case->id", $case, 'button', 'copy');
if($isLibCase and common::hasPriv('testsuite', 'createCase')) echo html::a($this->createLink('testsuite', 'createCase', "libID=$case->lib&moduleID=$case->module&param=$case->id", $case), "<i class='icon-copy'></i>", '', "class='btn' title='{$lang->testcase->copy}'");
if($isLibCase and common::hasPriv('caselib', 'createCase')) echo html::a($this->createLink('caselib', 'createCase', "libID=$case->lib&moduleID=$case->module&param=$case->id", $case), "<i class='icon-copy'></i>", '', "class='btn' title='{$lang->testcase->copy}'");
common::printIcon('testcase', 'delete', "caseID=$case->id", $case, 'button', 'trash', 'hiddenwin');
?>
<?php endif;?>