本文整理汇总了PHP中Division::findUnassigned方法的典型用法代码示例。如果您正苦于以下问题:PHP Division::findUnassigned方法的具体用法?PHP Division::findUnassigned怎么用?PHP Division::findUnassigned使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Division
的用法示例。
在下文中一共展示了Division::findUnassigned方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct($user, $member)
{
// leadership notifications
if ($user->role > 1) {
// expired or pending leaves of absence
if (LeaveOfAbsence::count_expired($member->game_id) > 0 || LeaveOfAbsence::count_pending($member->game_id) > 0) {
array_push($this->messages, "<div class='alert alert-warning'><i class='fa fa-clock-o fa-lg'></i> There are leaves of absence that require your attention <a href='manage/leaves-of-absence' class='alert-link'>Manage Leaves of Absence</a></div>");
}
}
// division CO / XO
if ($user->role > 2) {
if (count(Division::findUnassigned($member->game_id))) {
array_push($this->messages, "<div class=\"alert alert-warning\"><i class=\"fa fa-exclamation-circle\"></i> Your division has unassigned members. Visit your division page to resolve this.</div>");
}
}
if (!User::isValidated()) {
array_push($this->messages, "<div class='alert alert-info'><i class='fa fa-envelope fa-lg'></i> Your account email has not been verified. <a href='#' class='alert-link send-email-validation' data-email='{$user->email}'>Send Validation</a></div>");
}
}
示例2:
<?php
if (count($division)) {
?>
<?php
if ($user->role >= 3 && $member->game_id === $division->id || User::isDev()) {
?>
<?php
$unassigned = Division::findUnassigned($division->id);
?>
<?php
if (count($unassigned)) {
?>
<div class="container margin-top-20">
<div class="alert alert-danger"><i class="fa fa-exclamation-circle"></i> <strong>Heads up!</strong> Your
division has unassigned members. Drag them onto a <?php
echo Locality::run('platoon', $division->id);
?>
to assign them. Ensure they have been formally recruited.
</div>
</div>
<?php
}
?>
<?php
}
?>
<div class='container'>
<ul class='breadcrumb'>
<li><a href='./'>Home</a></li>