本文整理汇总了PHP中thebuggenie\core\entities\Project::getID方法的典型用法代码示例。如果您正苦于以下问题:PHP Project::getID方法的具体用法?PHP Project::getID怎么用?PHP Project::getID使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类thebuggenie\core\entities\Project
的用法示例。
在下文中一共展示了Project::getID方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getIncomingEmailAccountsForProject
public function getIncomingEmailAccountsForProject(Project $project)
{
return IncomingEmailAccount::getAllByProjectID($project->getID());
}
示例2: canAssignScrumUserStories
/**
* Return if the user can assign scrum user stories
*
* @param \thebuggenie\core\entities\Project $project
*
* @return boolean
*/
public function canAssignScrumUserStories(\thebuggenie\core\entities\Project $project)
{
if ($project->isArchived()) {
return false;
}
if ($this->canSaveConfiguration(framework\Settings::CONFIGURATION_SECTION_PROJECTS)) {
return true;
}
if ($project->getOwner() instanceof User && $project->getOwner()->getID() == $this->getID()) {
return true;
}
$retval = $this->hasPermission('canassignscrumuserstoriestosprints', $project->getID());
$retval = $retval !== null ? $retval : $this->hasPermission('candoscrumplanning', $project->getID());
$retval = $retval !== null ? $retval : $this->hasPermission('canassignscrumuserstoriestosprints', 0);
$retval = $retval !== null ? $retval : $this->hasPermission('candoscrumplanning', 0);
return (bool) ($retval !== null) ? $retval : false;
}
示例3: getSubprojectsArray
public static function getSubprojectsArray(Project $project, &$projects)
{
$projects[$project->getID()] = $project;
foreach ($project->getChildProjects() as $subproject) {
self::getSubprojectsArray($subproject, $projects);
}
}
示例4: hasProjectPageAccess
/**
* Check whether the user can access the specified project page
*
* @param string $page The page key
* @param Project $project
*
* @return boolean
*/
public function hasProjectPageAccess($page, Project $project)
{
$retval = $this->hasPageAccess($page, $project->getID());
$retval = $retval === null ? $this->hasPageAccess('project_allpages', $project->getID()) : $retval;
if ($retval === null) {
if ($project->getOwner() instanceof User && $project->getOwner()->getID() == $this->getID()) {
return true;
}
if ($project->getLeader() instanceof User && $project->getLeader()->getID() == $this->getID()) {
return true;
}
}
return $retval !== null ? $retval : framework\Settings::isPermissive();
}
示例5: convertIssueStepByIssuetype
/**
* Move issues from one step to another for a given issue type and conversions
* @param \thebuggenie\core\entities\Project $project
* @param \thebuggenie\core\entities\Issuetype $type
* @param array $conversions
*
* $conversions should be an array containing arrays:
* array (
* array(oldstep, newstep)
* ...
* )
*/
public function convertIssueStepByIssuetype(\thebuggenie\core\entities\Project $project, \thebuggenie\core\entities\Issuetype $type, array $conversions)
{
foreach ($conversions as $conversion) {
$crit = $this->getCriteria();
$crit->addWhere(self::PROJECT_ID, $project->getID());
$crit->addWhere(self::ISSUE_TYPE, $type->getID());
$crit->addWhere(self::WORKFLOW_STEP_ID, $conversion[0]);
$crit->addUpdate(self::WORKFLOW_STEP_ID, $conversion[1]);
$this->doUpdate($crit);
}
}