From 7535cb47bd3466aad37374a89cea73548613e403 Mon Sep 17 00:00:00 2001 From: hufangzhou Date: Fri, 12 Apr 2024 13:24:05 +0800 Subject: [PATCH] * Fix bug #47767, add stage list link Session for return link during creation. --- module/programplan/control.php | 4 ++-- module/project/control.php | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/module/programplan/control.php b/module/programplan/control.php index a7ed42fe9f..4a20a4a549 100644 --- a/module/programplan/control.php +++ b/module/programplan/control.php @@ -94,7 +94,7 @@ class programplan extends control if(!isset($errors['message'])) $this->send(array('result' => 'fail', 'callback' => array('name' => 'addRowErrors', 'params' => array($errors)))); } - $locate = $this->createLink('project', 'execution', "status=all&projectID={$projectID}&orderBy=order_asc&productID={$productID}"); + $locate = $this->session->projectPlanList ? $this->session->projectPlanList : $this->createLink('project', 'execution', "status=all&projectID={$projectID}&orderBy=order_asc&productID={$productID}"); $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => $locate)); } @@ -122,7 +122,7 @@ class programplan extends control if($executionType != 'stage') unset($this->lang->execution->typeList[''], $this->lang->execution->typeList['stage']); /* Unset percent for create IPD project.*/ - if($project->model == 'ipd') $this->config->programplan->list->customCreateFields = str_replace(',percent', '', $this->config->programplan->list->customCreateFields); + if($project->model == 'ipd') $this->config->programplan->list->customCreateFields = str_replace(',percent', '', $this->config->programplan->list->customCreateFields); $viewData = new stdclass(); $viewData->productID = $productID; diff --git a/module/project/control.php b/module/project/control.php index 864be44d02..51d5aff2dd 100755 --- a/module/project/control.php +++ b/module/project/control.php @@ -751,7 +751,8 @@ class project extends control $this->loadModel('task'); $this->loadModel('programplan'); $this->loadModel('product'); - $this->session->set('executionList', $this->app->getURI(true), 'project'); + $this->session->set('executionList', $this->app->getURI(true), 'project'); + $this->session->set('projectPlanList', $this->app->getURI(true), 'project'); if($this->cookie->showTask) $this->session->set('taskList', $this->app->getURI(true), 'project');