本文整理匯總了PHP中app\models\Person::checkAvailability方法的典型用法代碼示例。如果您正苦於以下問題:PHP Person::checkAvailability方法的具體用法?PHP Person::checkAvailability怎麽用?PHP Person::checkAvailability使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類app\models\Person
的用法示例。
在下文中一共展示了Person::checkAvailability方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: function
</div> <!--row-->
</div> <!--col-->
</div>
<div class="spacer60"></div>
<?php
echo GridView::widget(['dataProvider' => $dataProvider, 'layout' => "{items}\n{pager}", 'columns' => [['class' => 'yii\\grid\\CheckboxColumn', 'headerOptions' => ['width' => '30']], ['headerOptions' => ['width' => '100'], 'header' => $model->generateSegmentFilterDropdown($list_type_id), 'label' => 'Availability', 'format' => 'raw', 'value' => function ($data) use($model) {
return Person::checkAvailability($data->id, $model->id);
}, 'visible' => $list_type_id == 1 ? 1 : 0], ['headerOptions' => ['width' => '100'], 'header' => '<div class="text-center">Client<br />Approved</div>', 'format' => 'raw', 'visible' => $list_type_id == 1 ? 1 : 0, 'value' => function ($data) use($model) {
if (Person::isClientApproved($data->id, $model->id) == 'approved') {
return '<div class="text-center"><div class="btn btn-xs btn-success"><span class="glyphicon glyphicon-ok"></span></div></div>';
}
if (Person::isClientApproved($data->id, $model->id) == 'denied') {
return '<div class="text-center"><div class="btn btn-xs btn-danger"><span class="glyphicon glyphicon-remove"></span></div></div>';
}
return false;
}], ['headerOptions' => ['width' => '130'], 'label' => 'Confirmed', 'format' => 'raw', 'value' => function ($data) use($model) {
return Person::checkConfirmed($data->id, $model->id);
}, 'visible' => $list_type_id == 2 ? 2 : 0], ['headerOptions' => ['width' => '20'], 'format' => 'raw', 'value' => function ($data) {
return $data->generateThumb();
}], ['headerOptions' => ['width' => '140'], 'attribute' => 'fname'], 'lname', ['attribute' => 'Gender', 'format' => 'raw', 'value' => function ($model) {
return ucfirst($model->gender);
}], ['headerOptions' => ['width' => '150'], 'header' => $model->generateRoleFilterDropdown($list_type_id), 'contentOptions' => ['class' => 'text-center'], 'label' => 'Role', 'format' => 'raw', 'value' => function ($data) use($model) {