From 7c3a8dc7531bd6f61c3caa96f3cf5c54f5f2de0a Mon Sep 17 00:00:00 2001 From: tianshujie Date: Wed, 8 Dec 2021 16:50:48 +0800 Subject: [PATCH] * Fix bug #17259. --- module/execution/control.php | 1 + module/execution/model.php | 5 +++-- module/execution/view/manageproducts.html.php | 4 ++-- module/project/control.php | 1 + module/project/view/manageproducts.html.php | 4 ++-- 5 files changed, 9 insertions(+), 6 deletions(-) diff --git a/module/execution/control.php b/module/execution/control.php index 5d8052a3c0..62b5adcacf 100644 --- a/module/execution/control.php +++ b/module/execution/control.php @@ -2431,6 +2431,7 @@ class execution extends control $this->view->unmodifiableBranches = $unmodifiableBranches; $this->view->linkedBranches = $linkedBranches; $this->view->branchGroups = $this->execution->getBranchByProduct(array_keys($allProducts), $this->config->systemMode == 'new' ? $execution->project : 0); + $this->view->allBranches = $this->execution->getBranchByProduct(array_keys($allProducts), $this->config->systemMode == 'new' ? $execution->project : 0, 'all'); $this->display(); } diff --git a/module/execution/model.php b/module/execution/model.php index 56e0a41dcd..c6df3884a1 100644 --- a/module/execution/model.php +++ b/module/execution/model.php @@ -1676,12 +1676,13 @@ class executionModel extends model * * @param array $products * @param int $projectID + * @param string $param * @access public * @return array */ - public function getBranchByProduct($products, $projectID = 0) + public function getBranchByProduct($products, $projectID = 0, $param = 'noclosed') { - $branchGroups = $this->loadModel('branch')->getByProducts($products, 'noclosed'); + $branchGroups = $this->loadModel('branch')->getByProducts($products, $param); if($projectID) { diff --git a/module/execution/view/manageproducts.html.php b/module/execution/view/manageproducts.html.php index fcb8b30cad..ad4c9d192a 100644 --- a/module/execution/view/manageproducts.html.php +++ b/module/execution/view/manageproducts.html.php @@ -33,12 +33,12 @@ execution->notAllowRemoveProducts : $productName;?>
-
'> +
'>
";?>
- +
diff --git a/module/project/control.php b/module/project/control.php index fbfcdfef1d..569d89868f 100644 --- a/module/project/control.php +++ b/module/project/control.php @@ -1797,6 +1797,7 @@ class project extends control $this->view->unmodifiableBranches = $unmodifiableBranches; $this->view->unmodifiableMainBranches = $unmodifiableMainBranches; $this->view->branchGroups = $this->loadModel('branch')->getByProducts(array_keys($allProducts), 'ignoreNormal|noclosed'); + $this->view->allBranches = $this->branch->getByProducts(array_keys($allProducts), 'ignoreNormal'); $this->display(); } diff --git a/module/project/view/manageproducts.html.php b/module/project/view/manageproducts.html.php index d42d76fe6a..cabdf182d6 100644 --- a/module/project/view/manageproducts.html.php +++ b/module/project/view/manageproducts.html.php @@ -32,12 +32,12 @@ project->notAllowRemoveProducts : $productName;?>
-
'> +
'>
";?>
- +