This commit is contained in:
wangyuting
2022-11-30 06:41:40 +00:00
parent c71b65d8b0
commit 89edb08198
11 changed files with 30 additions and 7 deletions
+1
View File
@@ -60,6 +60,7 @@ $lang->build->notice->changeProduct = "The {$lang->SRCommon}, bug, or the vers
$lang->build->notice->changeExecution = "The version of the submitted test order cannot be modified {$lang->executionCommon}";
$lang->build->notice->changeBuilds = "The version of the submitted test order cannot be modified builds";
$lang->build->notice->autoRelation = "The completed requirements, resolved bugs, and generated bugs under the relevant version will be automatically associated with the project version";
$lang->build->notice->createTest = "The execution of this version has been deleted, and the test cannot be submitted";
$lang->build->finishStories = " %s {$lang->SRCommon} sind abgeschlossen.";
$lang->build->resolvedBugs = ' %s Bugs sind gelöst.';
+1
View File
@@ -60,6 +60,7 @@ $lang->build->notice->changeProduct = "The {$lang->SRCommon}, bug, or the vers
$lang->build->notice->changeExecution = "The version of the submitted test order cannot be modified {$lang->executionCommon}";
$lang->build->notice->changeBuilds = "The version of the submitted test order cannot be modified builds";
$lang->build->notice->autoRelation = "The completed requirements, resolved bugs, and generated bugs under the relevant version will be automatically associated with the project version";
$lang->build->notice->createTest = "The execution of this version has been deleted, and the test cannot be submitted";
$lang->build->finishStories = " Finished {$lang->SRCommon} %s";
$lang->build->resolvedBugs = ' Resolved Bug %s';
+1
View File
@@ -60,6 +60,7 @@ $lang->build->notice->changeProduct = "The {$lang->SRCommon}, bug, or the vers
$lang->build->notice->changeExecution = "The version of the submitted test order cannot be modified {$lang->executionCommon}";
$lang->build->notice->changeBuilds = "The version of the submitted test order cannot be modified builds";
$lang->build->notice->autoRelation = "The completed requirements, resolved bugs, and generated bugs under the relevant version will be automatically associated with the project version";
$lang->build->notice->createTest = "The execution of this version has been deleted, and the test cannot be submitted";
$lang->build->finishStories = " {$lang->SRCommon} Terminées %s";
$lang->build->resolvedBugs = ' Bugs Résolus %s';
+1
View File
@@ -54,6 +54,7 @@ $lang->build->notice->changeProduct = "The {$lang->SRCommon}, bug, or the vers
$lang->build->notice->changeExecution = "The version of the submitted test order cannot be modified {$lang->executionCommon}";
$lang->build->notice->changeBuilds = "The version of the submitted test order cannot be modified builds";
$lang->build->notice->autoRelation = "The completed requirements, resolved bugs, and generated bugs under the relevant version will be automatically associated with the project version";
$lang->build->notice->createTest = "The execution of this version has been deleted, and the test cannot be submitted";
$lang->build->finishStories = " {$lang->SRCommon} đã kết thúc %s";
$lang->build->resolvedBugs = ' Bug đã giải quyết %s';
+2
View File
@@ -60,6 +60,8 @@ $lang->build->notice->changeProduct = "已经关联{$lang->SRCommon}、Bug或
$lang->build->notice->changeExecution = "提交测试单的版本,不能修改其所属{$lang->executionCommon}";
$lang->build->notice->changeBuilds = "提交测试单的版本,不能修改关联版本";
$lang->build->notice->autoRelation = "相关版本下完成的需求、解决的Bug、产生的Bug将会自动关联到项目版本中";
$lang->build->notice->createTest = "该版本所属执行已删除,不能提交测试";
$lang->build->finishStories = " 本次共完成 %s 个{$lang->SRCommon}";
$lang->build->resolvedBugs = ' 本次共解决 %s 个Bug';
+12 -2
View File
@@ -259,7 +259,7 @@ class buildModel extends model
}
$branchs = strpos($params, 'separate') === false ? "0,$branch" : $branch;
$allBuilds = $this->dao->select('t1.id, t1.name, t1.date, t1.deleted, t2.status as objectStatus, t3.id as releaseID, t3.status as releaseStatus, t4.name as branchName, t5.type as productType')->from(TABLE_BUILD)->alias('t1')
$allBuilds = $this->dao->select('t1.id, t1.name, t1.execution, t1.date, t1.deleted, t2.status as objectStatus, t3.id as releaseID, t3.status as releaseStatus, t4.name as branchName, t5.type as productType')->from(TABLE_BUILD)->alias('t1')
->beginIF($objectType === 'execution')->leftJoin(TABLE_EXECUTION)->alias('t2')->on('t1.execution = t2.id')->fi()
->beginIF($objectType === 'project')->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project = t2.id')->fi()
->leftJoin(TABLE_RELEASE)->alias('t3')->on("FIND_IN_SET(t1.id,t3.build)")
@@ -275,6 +275,8 @@ class buildModel extends model
->beginIF($branch !== 'all')->andWhere('t1.branch')->in("$branchs")->fi()
->orderBy('t1.date desc, t1.id desc')->fetchAll('id');
$executions = $this->dao->select('id, deleted')->from(TABLE_EXECUTION)->where('type')->eq('sprint')->andWhere('deleted')->eq('1')->fetchPairs();
/* Set builds and filter done executions and terminate releases. */
$builds = array();
$buildIdList = array();
@@ -283,6 +285,7 @@ class buildModel extends model
{
if(empty($build->releaseID) and (strpos($params, 'nodone') !== false) and ($build->objectStatus === 'done')) continue;
if((strpos($params, 'noterminate') !== false) and ($build->releaseStatus === 'terminate')) continue;
if((strpos($params, 'withexecution') !== false) and $build->execution and !empty($executions[$build->execution])) continue;
if($build->deleted == 1) $build->name .= ' (' . $this->lang->build->deleted . ')';
$branchName = $build->branchName ? $build->branchName : $this->lang->branch->main;
@@ -685,7 +688,14 @@ class buildModel extends model
if(common::hasPriv($module, 'linkstory') and common::canBeChanged('build', $build)) $menu .= $this->buildMenu($module, 'view', "{$params}&type=story&link=true", $build, $type, 'link', '', '', '', "data-app={$tab}", $this->lang->build->linkStory);
$menu .= $this->buildMenu('testtask', 'create', "product=$build->product&execution={$executionID}&build=$build->id&projectID=$build->project", $build, $type, 'bullhorn', '', '', '', $testtaskApp);
if($execution and $execution->deleted === '1')
{
if(common::hasPriv('testtask', 'create')) $menu .= html::a(helper::createLink('testtask', 'create', "product=$build->product&execution={$executionID}&build=$build->id&projectID=$build->project"), "<i class='icon-testtask-create icon-bullhorn'></i>", '', "class='btn' title='{$this->lang->build->notice->createTest}' disabled");
}
else
{
$menu .= $this->buildMenu('testtask', 'create', "product=$build->product&execution={$executionID}&build=$build->id&projectID=$build->project", $build, $type, 'bullhorn', '', '', '', $testtaskApp);
}
if($tab == 'execution' and !empty($execution->type) and $execution->type != 'kanban') $menu .= $this->buildMenu('execution', 'bug', "execution={$extraParams['executionID']}&productID={$extraParams['productID']}&branchID=all&orderBy=status&build=$build->id", $build, $type, '', '', '', '', $this->lang->execution->viewBug);
if($tab == 'project' or empty($execution->type) or $execution->type == 'kanban') $menu .= $this->buildMenu($module, 'view', "{$params}&type=generatedBug", $build, $type, 'bug', '', '', '', "data-app='$tab'", $this->lang->project->bug);
+8 -2
View File
@@ -250,7 +250,7 @@ class testtask extends control
/* Create testtask from testtask of test.*/
$productID = $productID ? $productID : key($this->products);
$executions = empty($productID) ? array() : $this->loadModel('product')->getExecutionPairsByProduct($productID, '', 'id_desc', $projectID, 'stagefilter');
$builds = empty($productID) ? array() : $this->loadModel('build')->getBuildPairs($productID, 'all', 'notrunk');
$builds = empty($productID) ? array() : $this->loadModel('build')->getBuildPairs($productID, 'all', 'notrunk,withexecution', $projectID, 'project');
$execution = $this->loadModel('execution')->getByID($executionID);
if(!empty($execution) and $execution->type == 'kanban') $this->lang->testtask->execution = str_replace($this->lang->execution->common, $this->lang->kanban->common, $this->lang->testtask->execution);
@@ -816,13 +816,18 @@ class testtask extends control
$executions[$executionID] = $project->name . "({$this->lang->project->disableExecution})";
}
}
$builds = $this->loadModel('build')->getBuildPairs($productID, 'all', 'noempty,notrunk,withexecution', $executionID, 'execution');
}
else
{
$builds = $this->loadModel('build')->getBuildPairs($productID, 'all', 'noempty,notrunk,withexecution', $task->project, 'project');
}
$this->view->title = $this->products[$productID] . $this->lang->colon . $this->lang->testtask->edit;
$this->view->task = $task;
$this->view->project = $this->project->getByID($projectID);
$this->view->executions = $executions;
$this->view->builds = empty($productID) ? array() : $this->loadModel('build')->getBuildPairs($productID, 'all', 'noempty,notrunk', $executionID, 'execution');
$this->view->builds = empty($productID) ? array() : $builds;
$this->view->testreports = $this->loadModel('testreport')->getPairs($task->product, $task->testreport);
$this->view->users = $this->loadModel('user')->getPairs('nodeleted|noclosed', $task->owner);
$this->view->contactLists = $this->user->getContactLists($this->app->user->account, 'withnote');
@@ -1501,6 +1506,7 @@ class testtask extends control
$this->view->builds = $builds;
$this->view->users = $this->loadModel('user')->getPairs('noletter|nodeleted|noclosed');
$this->view->productID = $productID;
$this->view->projectID = $projectID;
$this->display();
}
+1 -2
View File
@@ -100,10 +100,9 @@ function loadExecutionBuilds(executionID, selected)
if(!selectedBuild) selectedBuild = 0;
var link = createLink('build', 'ajaxGetExecutionBuilds', 'executionID=' + executionID + '&productID=' + $('#product').val() + '&varName=testTaskBuild&build=' + selectedBuild);
if(executionID == 0) link = createLink('build', 'ajaxGetProductBuilds', 'productID=' + $('#product').val() + '&varName=resolvedBuild&build=' + selectedBuild);
if(executionID == 0) link = createLink('build', 'ajaxGetProjectBuilds', 'projectID=' + projectID + '&productID=' + $('#product').val() + '&varName=build&build=' + selectedBuild + '&branch=&index=&needCreate=&type=noempty,notrunk,withexecution');
$('#buildBox').load(link, function()
{
$('#resolvedBuild').attr('id', 'build').attr('name', 'build').find('option[value=trunk]').remove();
if(selected) $('#build').val(selected);
$('#build').chosen();
});
+1 -1
View File
@@ -8,7 +8,7 @@ function loadProductRelated()
{
loadExecutions($('#product').val());
loadTestReports($('#product').val());
loadExecutionRelated($('#execution').val())
loadExecutionBuilds($('#execution').val())
}
/**
+1
View File
@@ -13,6 +13,7 @@
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/datepicker.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<?php js::set('projectID', $task->project);?>
<div id='mainContent' class='main-content'>
<div class='center-block'>
<div class='main-header'>
@@ -107,4 +107,5 @@ $(function()
$('#subNavbar li[data-id="case"]').addClass('active');
})
</script>
<?php js::set('projectID', $projectID);?>
<?php include '../../common/view/footer.html.php';?>