From 6b671ddd1ee8cdedc2243bda1d05a33f616aa6bb Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 26 Aug 2022 09:23:05 +0800 Subject: [PATCH 1/4] * Fix bug #26852. --- module/product/view/browse.html.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/module/product/view/browse.html.php b/module/product/view/browse.html.php index 43f642332b..f234bbdbfd 100644 --- a/module/product/view/browse.html.php +++ b/module/product/view/browse.html.php @@ -290,14 +290,14 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : ''; $canBatchClose = (common::hasPriv($storyType, 'batchClose') and strtolower($browseType) != 'closedbyme' and strtolower($browseType) != 'closedstory'); $canBatchReview = ($canBeChanged and common::hasPriv($storyType, 'batchReview')); $canBatchChangeStage = ($canBeChanged and common::hasPriv('story', 'batchChangeStage') and $storyType == 'story'); - $canBatchChangeBranch = ($canBeChanged and common::hasPriv($storyType, 'batchChangeBranch')); + $canBatchChangeBranch = ($canBeChanged and common::hasPriv($storyType, 'batchChangeBranch') and $this->session->currentProductType and $this->session->currentProductType != 'normal' and $productID); $canBatchChangeModule = ($canBeChanged and common::hasPriv($storyType, 'batchChangeModule')); $canBatchChangePlan = ($canBeChanged and common::hasPriv('story', 'batchChangePlan') and $storyType == 'story'); $canBatchAssignTo = ($canBeChanged and common::hasPriv($storyType, 'batchAssignTo')); $canBatchUnlink = ($canBeChanged and $this->app->tab == 'project' and common::hasPriv('projectstory', 'batchUnlinkStory')); $canBatchImportToLib = ($canBeChanged and $this->app->tab == 'project' and isset($this->config->maxVersion) and common::hasPriv('story', 'batchImportToLib')); - $canBatchAction = ($canBatchEdit or $canBatchClose or $canBatchReview or $canBatchChangeStage or $canBatchChangeModule or $canBatchChangePlan or $canBatchAssignTo or $canBatchUnlink or $canBatchImportToLib); + $canBatchAction = ($canBatchEdit or $canBatchClose or $canBatchReview or $canBatchChangeStage or $canBatchChangeModule or $canBatchChangePlan or $canBatchAssignTo or $canBatchUnlink or $canBatchImportToLib or $canBatchChangeBranch); ?> ';?> ' id='storyList' data-fixed-left-width='' data-fixed-right-width=''> @@ -442,7 +442,7 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : ''; echo "
  • " . html::a('javascript:;', $lang->story->review, '', $class) . '
  • '; } - if($canBatchChangeBranch and $this->session->currentProductType and $this->session->currentProductType != 'normal' and $productID) + if($canBatchChangeBranch) { $withSearch = count($branchTagOption) > 8; echo "