本文整理匯總了PHP中thebuggenie\core\entities\User::doesIDExist方法的典型用法代碼示例。如果您正苦於以下問題:PHP User::doesIDExist方法的具體用法?PHP User::doesIDExist怎麽用?PHP User::doesIDExist使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類thebuggenie\core\entities\User
的用法示例。
在下文中一共展示了User::doesIDExist方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: hasValidTarget
public function hasValidTarget()
{
if (!$this->_target_value) {
return true;
}
switch ($this->_action_type) {
case self::ACTION_ASSIGN_ISSUE:
$target_details = explode('_', $this->_target_value);
return (bool) ($target_details[0] == 'user') ? \thebuggenie\core\entities\User::doesIDExist($target_details[1]) : Team::doesIDExist($target_details[1]);
break;
case self::ACTION_SET_PERCENT:
return (bool) ($this->_target_value > -1);
break;
case self::ACTION_SET_MILESTONE:
return (bool) Milestone::doesIDExist($this->_target_value);
break;
case self::ACTION_SET_PRIORITY:
return (bool) Priority::has($this->_target_value);
break;
case self::ACTION_SET_STATUS:
return (bool) Status::has($this->_target_value);
break;
case self::ACTION_SET_REPRODUCABILITY:
return (bool) Reproducability::has($this->_target_value);
break;
case self::ACTION_SET_RESOLUTION:
return (bool) Resolution::has($this->_target_value);
break;
default:
return true;
}
}