/var/www/vhosts/nabawater/backend/views/branch
NameSizeModeActions
create.php10780644editdlrm
files.php3910644editdlrm
image-uplaod.php4910644editdlrm
index.php155180644editdlrm
update.php12190755editdlrm
_form.php208050755editdlrm
_timeslot.php337620644editdlrm
Edit: /var/www/vhosts/nabawater/backend/views/branch/index.php (15518B)
title = yii::t('backend','Branch Management'); ?>

title ?> '.' '. Yii::t('backend', 'Create'), ['create'], ['class' => 'btn btn-info d-none d-lg-block m-l-15 pull-right']) ?>

$dataProvider, 'filterModel' => $searchModel, 'columns' => [ ['class' => \yii\grid\SerialColumn::className()], 'branch_name', [ 'attribute' => 'contact_email', 'label' => yii::t('backend','Contact Email'), 'value' => 'contact_email' ], [ 'attribute' => 'contact_number', 'label' => yii::t('backend','Contact Number'), 'value' => 'contact_number' ], [ 'attribute' => 'branch_status', 'label' => yii::t('backend','Branch Status'), 'format' => 'raw', 'headerOptions' => ['style' => 'width:13%'], 'filter' => [Branch::ACTIVE => yii::t('backend','active'), Branch::INACTIVE => yii::t('backend','Inactive')], 'filterInputOptions' => ['class' => 'select2 form-control', 'prompt' => yii::t('backend','All')], 'value' => function (Branch $model) { $id = Html::getInputId($model, 'branch_status') . "-{$model->getPrimaryKey()}"; $html = Html::activeCheckbox($model, 'branch_status', ['data-size'=> 'mini','data-toggle' => 'switch', 'label' => false, 'id' => $id]); $html .= Html::tag('span', Html::label('', $id)); return Html::tag('div', $html, ['class' => 'bootstrap-switch']); } ], [ 'attribute' => 'area', 'label' => yii::t('backend','Area'), 'visible' => ($rowvisible==0) , 'value' => 'vendor_name' ], [ 'attribute' => 'city', 'label' => yii::t('backend','City'), 'visible' => ($rowvisible==0) , 'value' => 'vendor_name' ], [ 'attribute' => 'branch_availability_status', 'label' => yii::t('backend','Branch Availability Status'), 'format' => 'raw', 'filter' => [ Branch::AVAILABITIY_OPEN => yii::t('backend','open'), Branch::AVAILABILITY_CLOSED => yii::t('backend','closed'), /* Branch::AVAILABILITY_PREORDER => yii::t('backend','pre-order'),*/ Branch::AVAILABILITY_BUSY => yii::t('backend','busy') ], 'filterInputOptions' => ['class' => 'select2 form-control col-md-10 ', 'id' => 'branch_availability_status' ,'prompt' => yii::t('backend','All')], 'value' => function (Branch $model) { return Html::activeDropDownList($model, 'branch_availability_status', $model->getAvailabilityStatus(), ['class' => 'select2 form-control col-md-10 avilable-status'] ); } ], [ 'class' => \yii\grid\ActionColumn::className(), 'header' => Yii::t('backend', 'Actions'), 'template' => '{timeslot}{update}{stock}{change-password}{delete}', 'buttons' => [ 'timeslot' => function ($url, $model, $key) { $html = Html::tag('span', '', ['class' => 'fa fa-clock-o text-inverse m-r-10 ']); return Html::a($html, ['branch/time-slot', 'id' => $key]); }, 'update' => function ($url, $model, $key) { $html = Html::tag('span', '', ['class' => 'fa fa-pencil text-inverse m-r-10']); return Html::a($html, $url); }, 'stock' => function ($url, $model, $key) { $html = Html::tag('span', '', ['class' => 'fa fa-shopping-cart m-r-10']); return Html::a($html, 'stock?ItemSearch[branch_name]='.$model->getPrimaryKey()); }, 'delete' => function ($url, $model, $key) { $html = Html::tag('span', '', ['class' => 'fa fa-trash-o']); return Html::a($html, $url, [ 'data-pjax' => '0', 'data-confirm' => yii::t('backend', 'Are you sure you want to delete this item?'), 'data-method' => 'post' ]); }, 'change-password' => function ($url, $model, $key) { if(AdminUser::isVendor()){ return ; }; return Html::a('' ,'javascript:;'); }, ], ], ], ]); ?>