From c265149f88dc29bae1aa889b83a4157c1fee3f4b Mon Sep 17 00:00:00 2001 From: tianshujie Date: Thu, 30 Jun 2022 10:19:52 +0800 Subject: [PATCH 1/3] * Fix bug #24586. --- module/task/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/task/model.php b/module/task/model.php index 5c4c9b61f3..a2bf1a74d9 100644 --- a/module/task/model.php +++ b/module/task/model.php @@ -831,7 +831,7 @@ class taskModel extends model $currentTask->consumed += (float)$member->consumed; $currentTask->left += (float)$member->left; } - if(empty($oldTask->team)) $currentTask->consumed += (float)$oldTask->consumed; + if(empty($oldTask->team) and isset($oldTask->consumed)) $currentTask->consumed += (float)$oldTask->consumed; if(!empty($task)) { From 8fbf4148c4d49350c0e1fb7b66610bfc11b74501 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Thu, 30 Jun 2022 10:55:05 +0800 Subject: [PATCH 2/3] * Fix bug #24573. --- module/task/view/view.html.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/task/view/view.html.php b/module/task/view/view.html.php index c4a4d4f31b..e2f4091aa7 100644 --- a/module/task/view/view.html.php +++ b/module/task/view/view.html.php @@ -166,7 +166,7 @@
- + ' . $lang->goback, '', "class='btn btn-secondary'");?>
";?> executionList = $execution;?> task->buildOperateMenu($task, 'view');?> From 7528cdfdcf4b1e472658427a5dd0277fb3088c15 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Thu, 30 Jun 2022 13:16:31 +0800 Subject: [PATCH 3/3] * Fix bug #24554. --- lib/base/front/front.class.php | 2 -- module/product/control.php | 12 ++++++------ module/story/model.php | 3 ++- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/lib/base/front/front.class.php b/lib/base/front/front.class.php index 4c18838dfb..9afe2605e6 100644 --- a/lib/base/front/front.class.php +++ b/lib/base/front/front.class.php @@ -501,8 +501,6 @@ class baseHTML $gobackList = isset($_COOKIE['goback']) ? json_decode($_COOKIE['goback'], true) : array(); $gobackLink = isset($gobackList[$tab]) ? $gobackList[$tab] : ''; - if(strpos($misc, 'data-app') === false) $misc .= " data-app='" . $tab . "'"; - /* If the link of the referer is not the link of the current page or the link of the index, the cookie and gobackLink will be updated. */ if(!preg_match("/(m=|\/)(index|search|$currentModule)(&f=|-)(index|buildquery|$currentMethod)(&|-|\.)?/", strtolower($refererLink))) { diff --git a/module/product/control.php b/module/product/control.php index 4f724735e9..1108ea3e27 100644 --- a/module/product/control.php +++ b/module/product/control.php @@ -148,18 +148,18 @@ class product extends control } /* Set menu. */ - if($this->app->tab == 'product') + if($this->app->tab == 'project') + { + $this->session->set('storyList', $this->app->getURI(true), 'project'); + $this->loadModel('project')->setMenu($projectID); + } + else { $this->session->set('storyList', $this->app->getURI(true), 'product'); $this->session->set('productList', $this->app->getURI(true), 'product'); $this->product->setMenu($productID, $branch, 0, '', "storyType=$storyType"); } - if($this->app->tab == 'project') - { - $this->session->set('storyList', $this->app->getURI(true), 'project'); - $this->loadModel('project')->setMenu($projectID); - } /* Lower browse type. */ $browseType = strtolower($browseType); diff --git a/module/story/model.php b/module/story/model.php index d531c354e5..7ffad37ed8 100644 --- a/module/story/model.php +++ b/module/story/model.php @@ -3892,7 +3892,8 @@ class storyModel extends model $menu .= $this->buildMenu('story', 'close', $params, $story, $type, '', '', 'iframe', true); $menu .= $this->buildMenu('story', 'edit', $params . "&from=$story->from", $story, $type); - if($story->type != 'requirement' and $this->config->vision != 'lite') $menu .= $this->buildMenu('story', 'createCase', "productID=$story->product&branch=$story->branch&module=0&from=¶m=0&$params", $story, $type, 'sitemap', '', '', false, "data-app='qa'"); + $tab = $this->app->tab == 'project' ? 'project' : 'qa'; + if($story->type != 'requirement' and $this->config->vision != 'lite') $menu .= $this->buildMenu('story', 'createCase', "productID=$story->product&branch=$story->branch&module=0&from=¶m=0&$params", $story, $type, 'sitemap', '', '', false, "data-app='$tab'"); if($this->app->rawModule != 'projectstory' OR $this->config->vision == 'lite') {