* Finish task #45040.

This commit is contained in:
songchenxuan
2021-12-01 08:45:25 +08:00
parent 9b6c38f289
commit cb00625795
4 changed files with 27 additions and 0 deletions
+1
View File
@@ -31,6 +31,7 @@ $lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->project = 'Project';
$lang->build->branch = 'Platform/Branch';
$lang->build->branchName = '%s';
$lang->build->execution = $lang->executionCommon;
$lang->build->name = 'Name';
$lang->build->date = 'Date';
+1
View File
@@ -31,6 +31,7 @@ $lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->project = '所属项目';
$lang->build->branch = '平台/分支';
$lang->build->branchName = '所属%s';
$lang->build->execution = '所属' . $lang->executionCommon;
$lang->build->name = '名称编号';
$lang->build->date = '打包日期';
+13
View File
@@ -1007,6 +1007,19 @@ class execution extends control
$type = strtolower($type);
$queryID = ($type == 'bysearch') ? (int)$param : 0;
$actionURL = $this->createLink('execution', 'build', "executionID=$executionID&type=bysearch&queryID=myQueryID");
if($param)
{
$product = $this->loadModel('product')->getById($param);
if($product and $product->type != 'normal')
{
$this->loadModel('build');
$this->loadModel('branch');
$branches = array(BRANCH_MAIN => $this->lang->branch->main) + $this->branch->getPairs($product->id, '', $executionID);
$this->config->build->search['fields']['branch'] = sprintf($this->lang->build->branchName, $this->lang->product->branchName[$product->type]);
$this->config->build->search['params']['branch'] = array('operator' => '=', 'control' => 'select', 'values' => $branches);
}
}
$this->project->buildProjectBuildSearchForm($products, $queryID, $actionURL, 'execution');
/* Get builds. */
+12
View File
@@ -1073,6 +1073,18 @@ class project extends control
$this->config->build->search['fields']['execution'] = $this->project->lang->executionCommon;
$this->config->build->search['params']['execution'] = array('operator' => '=', 'control' => 'select', 'values' => array('' => '') + $executions);
if($param)
{
$product = $this->loadModel('product')->getById($param);
if($product and $product->type != 'normal')
{
$this->loadModel('build');
$this->loadModel('branch');
$branches = array(BRANCH_MAIN => $this->lang->branch->main) + $this->branch->getPairs($product->id, '', $projectID);
$this->config->build->search['fields']['branch'] = sprintf($this->lang->build->branchName, $this->lang->product->branchName[$product->type]);
$this->config->build->search['params']['branch'] = array('operator' => '=', 'control' => 'select', 'values' => $branches);
}
}
$this->project->buildProjectBuildSearchForm($products, $queryID, $actionURL, 'project');
if($type == 'bysearch')