From 68bad00edcec4dd44719b2a9e7fd0622c8a39f32 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Thu, 16 Mar 2023 11:11:26 +0800 Subject: [PATCH] * Code for fix bug #32989. --- module/story/control.php | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/module/story/control.php b/module/story/control.php index e7698cfb49..e98a0e4ed9 100755 --- a/module/story/control.php +++ b/module/story/control.php @@ -1267,9 +1267,14 @@ class story extends control if($this->app->tab == 'project') { - $module = 'projectstory'; - $method = 'view'; - $params = "storyID=$storyID"; + $module = 'projectstory'; + $method = 'view'; + $params = "storyID=$storyID"; + if(!$this->session->multiple) + { + $module = 'story'; + $params .= "&version=0¶m={$this->session->project}&storyType=$storyType"; + } } elseif($this->app->tab == 'execution') { @@ -1283,7 +1288,8 @@ class story extends control $method = 'view'; $params = "storyID=$storyID&version=0¶m=0&storyType=$storyType"; } - return print(js::locate($this->createLink($module, $method, $params), 'parent')); + + return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => $this->createLink($module, $method, $params))); } $this->commonAction($storyID); @@ -1800,9 +1806,6 @@ class story extends control $story = $this->story->getById($storyID); $product = $this->product->getById($story->product); - /* Set menu. */ - $this->product->setMenu($story->product, $story->branch); - /* Get reviewers. */ $reviewers = $product->reviewer; if(!$reviewers and $product->acl != 'open') $reviewers = $this->loadModel('user')->getProductViewListUsers($product, '', '', '', '');