From 5b2b646db3a945acaf512a6b23ac7a74f68f71c7 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 4 Mar 2022 16:29:56 +0800 Subject: [PATCH] * Fix bug #20328. --- module/execution/model.php | 1 + module/project/model.php | 1 + 2 files changed, 2 insertions(+) diff --git a/module/execution/model.php b/module/execution/model.php index 29e476e65d..3c6ad82e4d 100644 --- a/module/execution/model.php +++ b/module/execution/model.php @@ -2483,6 +2483,7 @@ class executionModel extends model ->where('t1.root')->eq((int)$executionID) ->andWhere('t1.type')->eq('execution') ->andWhere('t2.deleted')->eq('0') + ->beginIF($this->config->vision)->andWhere("CONCAT(',', t2.visions, ',')")->like("%,{$this->config->vision},%")->fi() ->fetchAll('account'); } diff --git a/module/project/model.php b/module/project/model.php index b363a80342..317b5466a7 100644 --- a/module/project/model.php +++ b/module/project/model.php @@ -1841,6 +1841,7 @@ class projectModel extends model ->where('t1.root')->eq((int)$projectID) ->andWhere('t1.type')->eq($type) ->andWhere('t2.deleted')->eq('0') + ->beginIF($this->config->vision)->andWhere("CONCAT(',', t2.visions, ',')")->like("%,{$this->config->vision},%")->fi() ->fetchAll('account'); }