From 125fa381fcac7c1d31996761a413a8dd139ad1c0 Mon Sep 17 00:00:00 2001 From: zhouxin Date: Tue, 12 Apr 2022 07:40:28 +0000 Subject: [PATCH] * Fix bug #21374. --- module/product/view/browse.html.php | 2 -- module/story/control.php | 4 +++- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/module/product/view/browse.html.php b/module/product/view/browse.html.php index 61b03db2a5..26c870a36a 100644 --- a/module/product/view/browse.html.php +++ b/module/product/view/browse.html.php @@ -143,7 +143,6 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : ''; ?> - - diff --git a/module/story/control.php b/module/story/control.php index abfe4b164f..8c9bb6ad70 100644 --- a/module/story/control.php +++ b/module/story/control.php @@ -229,7 +229,9 @@ class story extends control /* Set products, users and module. */ if($objectID != 0) { - $products = $this->product->getProductPairsByProject($objectID); + global $config; + $onlyNoClosed = empty($config->CRProduct) ? 'noclosed' : ''; + $products = $this->product->getProductPairsByProject($objectID, $onlyNoClosed); $productID = empty($productID) ? key($products) : $productID; $product = $this->product->getById(($productID and array_key_exists($productID, $products)) ? $productID : key($products)); $productBranches = $product->type != 'normal' ? $this->loadModel('execution')->getBranchByProduct($productID, $objectID) : array();