From 7de8e1fd890bff601faf1f05c551044f25b2dcb3 Mon Sep 17 00:00:00 2001 From: qiyu-xie Date: Mon, 25 Jan 2021 15:05:28 +0800 Subject: [PATCH] * Finish task#9101. Change whitelist return. --- module/my/control.php | 1 - module/personnel/control.php | 6 ++++++ module/personnel/view/whitelist.html.php | 2 +- module/program/control.php | 3 --- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/module/my/control.php b/module/my/control.php index 518acaca57..ae2bd2655b 100644 --- a/module/my/control.php +++ b/module/my/control.php @@ -468,7 +468,6 @@ class my extends control $this->app->session->set('programList', $this->app->getURI(true)); $this->app->session->set('PRJBrowse', $this->app->getURI(true)); - $this->app->session->set('whitelist', $this->app->getURI(true)); /* Set the pager. */ $this->app->loadClass('pager', $static = true); diff --git a/module/personnel/control.php b/module/personnel/control.php index 7be1cc0288..b055adbac7 100644 --- a/module/personnel/control.php +++ b/module/personnel/control.php @@ -114,6 +114,11 @@ class personnel extends control $this->app->loadClass('pager', true); $pager = pager::init($recTotal, $recPerPage, $pageID); + /* Set back link. */ + $goback = $this->session->PRJBrowse ? $this->session->PRJBrowse : $this->createLink('program', 'PRJWhitelist', "projectID=$objectID"); + if($from == 'pgmbrowse') $goback = $this->createLink('program', 'PGMBrowse'); + if($from == 'pgmproject') $goback = $this->session->PGMProject ? $this->session->PGMProject : $this->createLink('program', 'PGMProject', "programID=$programID"); + $this->view->title = $this->lang->personnel->whitelist; $this->view->position[] = $this->lang->personnel->whitelist; @@ -122,6 +127,7 @@ class personnel extends control $this->view->whitelist = $this->personnel->getWhitelist($objectID, $objectType, $orderBy, $pager); $this->view->depts = $this->loadModel('dept')->getOptionMenu(); $this->view->module = $module; + $this->view->goback = $goback; $this->view->programID = $programID; $this->view->from = $from; diff --git a/module/personnel/view/whitelist.html.php b/module/personnel/view/whitelist.html.php index c1f96d2002..c9c77d4eb9 100644 --- a/module/personnel/view/whitelist.html.php +++ b/module/personnel/view/whitelist.html.php @@ -14,7 +14,7 @@