Merge branch 'sprint/182_liumengyi_fixbug' into 'kanban'

* FIx bug #18489,#18478,#18466.

See merge request easycorp/zentaopms!1420
This commit is contained in:
孙广明
2022-01-17 00:57:03 +00:00
8 changed files with 29 additions and 33 deletions
+2 -2
View File
@@ -1624,7 +1624,7 @@ class userModel extends model
if($allProducts === null) $allProducts = $this->dao->select('id,PO,QD,RD,createdBy,acl,whitelist,program,createdBy')->from(TABLE_PRODUCT)->where('acl')->ne('open')->fetchAll('id');
if($allProjects === null) $allProjects = $this->dao->select('id,PO,PM,QD,RD,acl,type,path,parent,openedBy')->from(TABLE_PROJECT)->where('acl')->ne('open')->andWhere('type')->eq('project')->fetchAll('id');
if($allPrograms === null) $allPrograms = $this->dao->select('id,PO,PM,QD,RD,acl,type,path,parent,openedBy')->from(TABLE_PROGRAM)->where('acl')->ne('open')->andWhere('type')->eq('program')->fetchAll('id');
if($allSprints === null) $allSprints = $this->dao->select('id,PO,PM,QD,RD,acl,project,path,parent,type,openedBy')->from(TABLE_PROJECT)->where('acl')->eq('private')->beginIF($this->config->systemMode == 'new')->andWhere('type')->in('sprint,stage')->fi()->fetchAll('id');
if($allSprints === null) $allSprints = $this->dao->select('id,PO,PM,QD,RD,acl,project,path,parent,type,openedBy')->from(TABLE_PROJECT)->where('acl')->eq('private')->beginIF($this->config->systemMode == 'new')->andWhere('type')->in('sprint,stage,kanban')->fi()->fetchAll('id');
/* Get teams. */
if($teams === null)
@@ -1869,7 +1869,7 @@ class userModel extends model
/* Set opened sprints and stages into userview. */
$openedSprints = $this->dao->select('id')->from(TABLE_PROJECT)
->where('acl')->eq('open')
->beginIF($this->config->systemMode == 'new')->andWhere('type')->in('sprint,stage')->fi()
->beginIF($this->config->systemMode == 'new')->andWhere('type')->in('sprint,stage,kanban')->fi()
->beginIF($this->config->systemMode == 'new')->andWhere('project')->in($userView->projects)->fi()
->fetchAll('id');