diff --git a/module/upgrade/control.php b/module/upgrade/control.php index 6514af3214..550a82ace7 100644 --- a/module/upgrade/control.php +++ b/module/upgrade/control.php @@ -284,7 +284,7 @@ class upgrade extends control $singleProducts = array_diff($linkedProducts, $sprintProducts); foreach($linkedSprints as $sprint) { - $this->upgrade->processMergedData($programID, $projectList[$sprint], $lineID, $sprintProducts[$sprint], array($sprint => $sprint)); + $this->upgrade->processMergedData($programID, $projectList[$sprint], $lineID, array($sprintProducts[$sprint] => $sprintProducts[$sprint]), array($sprint => $sprint)); } } @@ -339,7 +339,7 @@ class upgrade extends control $singleProducts = array_diff($linkedProducts, $sprintProducts); foreach($linkedSprints as $sprint) { - $this->upgrade->processMergedData($programID, $projectList[$sprint], $lineID, $sprintProducts[$sprint], array($sprint => $sprint)); + $this->upgrade->processMergedData($programID, $projectList[$sprint], $lineID, array($sprintProducts[$sprint] => $sprintProducts[$sprint]), array($sprint => $sprint)); } } diff --git a/module/upgrade/model.php b/module/upgrade/model.php index 9a89b940f2..db02558b12 100644 --- a/module/upgrade/model.php +++ b/module/upgrade/model.php @@ -4614,7 +4614,7 @@ class upgradeModel extends model */ public function computeObjectMembers() { - $projects = $this->dao->select('id,days')->from(TABLE_PROJECT)->where('type')->eq('project')->fetchAll('id'); + $projects = $this->dao->select('id,days')->from(TABLE_PROJECT)->where('type')->eq('project')->fetchAll('id'); $projectIdList = array_keys($projects); /* Get product and sprint team. */ @@ -4625,8 +4625,8 @@ class upgradeModel extends model ->where('t2.id')->in($projectIdList) ->fetchGroup('project', 'product'); $sprintGroups = $this->dao->select('*')->from(TABLE_PROJECT)->where('project')->in($projectIdList)->fetchGroup('project', 'id'); - $teamGroups = $this->dao->select('root,account')->from(TABLE_TEAM)->where('type')->eq('execution')->fetchGroup('root', 'account'); - $users = $this->dao->select('*')->from(TABLE_USER)->where('deleted')->eq('0')->fetchAll('account'); + $teamGroups = $this->dao->select('root,account')->from(TABLE_TEAM)->where('type')->eq('execution')->fetchGroup('root', 'account'); + $users = $this->dao->select('*')->from(TABLE_USER)->where('deleted')->eq('0')->fetchAll('account'); $groupAccounts = $this->dao->select('*')->from(TABLE_USERGROUP)->fetchGroup('group', 'account'); $projectTeams = array(); @@ -4703,7 +4703,7 @@ class upgradeModel extends model } $customSprints = $this->dao->select('*')->from(TABLE_PROJECT)->where('whitelist')->ne('')->andWhere('type')->in('sprint,stage')->fetchAll('id'); - $whitelistACL = $this->dao->select('account')->from(TABLE_ACL)->where('objectID')->in(array_keys($customSprints))->andWhere('objectType')->eq('sprint')->andWhere('type')->eq('whitelist')->fetchPairs('account'); + $whitelistACL = $this->dao->select('account')->from(TABLE_ACL)->where('objectID')->in(array_keys($customSprints))->andWhere('objectType')->eq('sprint')->andWhere('type')->eq('whitelist')->fetchPairs('account'); foreach($customSprints as $sprint) { if($sprint->acl != 'private') continue;