* Finish task #74209.

This commit is contained in:
Yagami
2022-11-01 16:09:54 +08:00
parent a8cb634609
commit 3d211b68b0
2 changed files with 4 additions and 1 deletions
+3 -1
View File
@@ -310,11 +310,13 @@ class build extends control
$this->executeHooks($buildID);
$buildIdList = $build->execution ? array() : array($buildID => $buildID);
/* Assign. */
$this->view->canBeChanged = common::canBeChanged('build', $build); // Determines whether an object is editable.
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->build = $build;
$this->view->buildPairs = $this->build->getBuildPairs(0, 'all', 'noempty,notrunk', $build->execution, 'execution');
$this->view->buildPairs = $this->build->getBuildPairs(0, 'all', 'noempty,notrunk', $build->execution, 'execution', $buildIdList);
$this->view->actions = $this->loadModel('action')->getList('build', $buildID);
$this->view->link = $link;
$this->view->param = $param;
+1
View File
@@ -235,6 +235,7 @@ class buildModel extends model
->beginIF($products)->andWhere('t1.product')->in($products)->fi()
->beginIF($objectType === 'execution' and $objectID)->andWhere('t1.execution')->eq($objectID)->fi()
->beginIF($objectType === 'project' and $objectID)->andWhere('t1.project')->eq($objectID)->fi()
->beginIF($objectType === 'execution' and !$objectID)->andWhere('t1.id')->in($buildIdList)->fi()
->beginIF($branch !== 'all')->andWhere('t1.branch')->in("0,$branch")->fi()
->orderBy('t1.date desc, t1.id desc')->fetchAll('id');