* Fix priv.

This commit is contained in:
Yagami
2020-10-30 11:00:21 +08:00
parent 055d52f45e
commit 1480098b5e
2 changed files with 17 additions and 2 deletions
+15
View File
@@ -2011,6 +2011,13 @@ class userModel extends model
}
}
/* Judge sprint auth. */
if(($project->type == 'sprint' || $project->type == 'stage') && $project->acl == 'private')
{
$parent = $this->dao->select('openedBy,PM')->from(TABLE_PROJECT)->where('id')->eq($project->project)->fetch();
if($parent->PM == $account || $parent->openedBy == $account) return true;
}
return false;
}
@@ -2093,6 +2100,14 @@ class userModel extends model
}
}
/* Judge sprint auth. */
if(($project->type == 'sprint' || $project->type == 'stage') && $project->acl == 'private')
{
$parent = $this->dao->select('openedBy,PM')->from(TABLE_PROJECT)->where('id')->eq($project->project)->fetch();
$users[$parent->openedBy] = $parent->openedBy;
$users[$parent->PM] = $parent->PM;
}
return $users;
}