From f3800e9e3838841e05096076ac90dbec31fabab0 Mon Sep 17 00:00:00 2001 From: hufangzhou Date: Tue, 21 Feb 2023 01:38:01 +0000 Subject: [PATCH] * Code for task #85049. --- module/project/control.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/module/project/control.php b/module/project/control.php index c7320064c3..c6d9d53c0a 100755 --- a/module/project/control.php +++ b/module/project/control.php @@ -167,10 +167,16 @@ class project extends control public function ajaxGetCopyProjects() { $data = fixer::input('post')->get(); + + $model = $data->model; + if($data->model == 'agileplus') $model = array('scrum', 'agileplus'); + if($data->model == 'waterfallplus') $model = array('waterfall', 'waterfallplus'); + $projectPairs = $this->dao->select('id, name')->from(TABLE_PROJECT) ->where('type')->eq('project') ->andWhere('deleted')->eq(0) ->andWhere('vision')->eq($this->config->vision) + ->andWhere('model')->in($model) ->beginIF(!$this->app->user->admin)->andWhere('id')->in($this->app->user->view->projects)->fi() ->beginIF(trim($data->name))->andWhere('name')->like("%$data->name%")->fi() ->fetchPairs();