本文整理汇总了PHP中Skill::getSkillsForUser方法的典型用法代码示例。如果您正苦于以下问题:PHP Skill::getSkillsForUser方法的具体用法?PHP Skill::getSkillsForUser怎么用?PHP Skill::getSkillsForUser使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Skill
的用法示例。
在下文中一共展示了Skill::getSkillsForUser方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: actionDisplayNextTableTeamMember
public static function actionDisplayNextTableTeamMember($team)
{
if (is_array($team) && count($team) > 0) {
foreach ($team as $member) {
$user = User::getEntity($member->getId());
$user->setPassword(null);
$user->setSalt(null);
$user->setPicture();
$member->setUser($user);
$member->setSkills(Skill::getSkillsForUser($member->getId()));
}
}
return $team;
}
示例2: actionGetEntity
public static function actionGetEntity()
{
if (isset($_GET['t']) && $_GET['t']) {
$table = $_GET['t'];
if (isset($_GET['i']) && $_GET['i'] && $_GET['i'] != null) {
$id = $_GET['i'];
} else {
$id = null;
}
if ($table == 'customers' && ControleurRights::canAddCustomer()) {
return Customer::getEntity($id);
} elseif ($table == 'team_member' && ControleurRights::canAddTeamMember()) {
$member = TeamMember::getEntity($id);
$member->setSkills(Skill::getSkillsForUser($id));
return $member;
} elseif ($table == 'users' && ControleurRights::canAddUser()) {
$user = User::getEntity($id);
$user->setPicture();
return $user;
} elseif ($table == 'projects' && ControleurRights::canDisplayProjects()) {
$project = Project::getEntity($id);
$project->setSkills(Skill::getSkillsForProject($id));
return $project;
} elseif ($table == 'plans' && ControleurRights::canDisplayPlans()) {
return Plan::getEntity($id);
} elseif ($table == 'right' && ControleurRights::canAddUser()) {
$right = Right::getEntity($id);
$rightClass = new ReflectionClass('RightColumnsLabel');
$right->setLabels($rightClass->getConstants());
return $right;
} elseif ($table == 'skills' && ControleurRights::canAddSkills()) {
return Skill::getEntity($id);
} else {
return "Table " . $table . " non configurée dans le CRUD ou interdiction d'accès à l'utilisateur";
}
}
}