示例#1
0
文件: index.php 项目: anli/yii2-rbac
/* @var $this yii\web\View */
$this->title = 'User Roles';
$this->params['breadcrumbs'][] = $this->title;
?>

<div class="row">
<?php 
Pjax::begin(['id' => 'container-pjax', 'timeout' => false]);
?>

    <!-- BEGIN customer portlet -->
    <div class="col-md-12">
    <?php 
Portlet::begin(['id' => 'user-portlet', 'title' => 'Users', 'subtitle' => 'showing all...', 'buttons' => [Html::a('<i class="fa fa-trash"></i>', ['user-role/delete-all'], ['title' => 'Delete All User Roles', 'class' => 'btn btn-circle red btn-sm', 'data-confirm' => 'Are you sure you want to delete all items?', 'data-method' => 'post', 'data-pjax' => 0])]]);
?>

    <?php 
echo GridView::widget(['id' => 'user-gridview', 'dataProvider' => $dataProvider, 'columns' => User::column()->username()->role()->actions('{update-user-role} {delete-user-role}')->all()]);
?>

    <?php 
Portlet::end();
?>
    </div>
    <!-- END customer portlet -->

<?php 
Pjax::end();
?>
</div>
示例#2
0
文件: view.php 项目: anli/yii2-auth0
$this->title = $model->name;
$this->params['breadcrumbs'][] = ['label' => 'Tenants', 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
//$this->params['sidebarItems'] = Yii::$app->params['sidebarItems'];
?>
<div class="row">
<?php 
Pjax::begin(['id' => 'container-pjax', 'timeout' => false]);
?>

    <!-- BEGIN user portlet -->
    <div class="col-md-6">
    <?php 
Portlet::begin(['id' => 'user-portlet', 'title' => 'Users Permission', 'subtitle' => 'for this tenant...']);
?>

    <?php 
echo GridView::widget(['id' => 'user-gridview', 'dataProvider' => new ArrayDataProvider(['allModels' => ApiUser::find()->email('')->orderBy('email:1')->all(), 'pagination' => ['pageSize' => 10]]), 'columns' => ApiUser::column()->nickname()->email()->role($model->name)->actions("{update-role-to-user} {update-role-to-admin} {remove-tenant}", $model->id)->all()]);
?>

    <?php 
Portlet::end();
?>
    </div>
    <!-- END user portlet -->

<?php 
Pjax::end();
?>
</div>
示例#3
0
文件: index.php 项目: anli/yii2-auth0
Portlet::end();
?>
    </div>
    <!-- END user portlet -->

    <!-- BEGIN tenant portlet -->
    <div class="col-md-6">
    <?php 
//Pjax::begin(['options' => ['id' => 'container-pjax']]);
?>
    <?php 
$checkboxButton = Html::a('<i class="fa fa-trash"></i> Delete selected', '#', ['title' => 'Delete Selected Tenant', 'class' => 'selectCheckboxButton', 'value-url' => 'http://localhost:8100/auth0/tenant/delete-checkbox', 'value-id' => 'tenant-gridview']);
Portlet::begin(['id' => 'tenant-portlet', 'title' => 'Tenants', 'subtitle' => 'showing  total users...', 'buttons' => [Html::a('<i class="fa fa-plus"></i>', false, ['value' => Url::to(['tenant/create']), 'title' => 'Create Tenant', 'class' => 'showModalButton btn btn-circle green-haze btn-sm']), Html::a('<i class="fa fa-download"></i>', false, ['value' => Url::to(['tenant/import']), 'title' => 'Import Tenant', 'class' => 'showModalButton btn btn-circle blue btn-sm']), Html::a('<i class="fa fa-cloud-download"></i>', ['tenant/export'], ['title' => 'Export Tenant', 'class' => 'btn btn-circle yellow btn-sm', 'data-pjax' => 0]), Html::a('<i class="fa fa-trash"></i>', ['tenant/delete-all'], ['title' => 'Delete All Tenant', 'class' => 'btn btn-circle red btn-sm', 'data-confirm' => 'Are you sure you want to delete all items?', 'data-method' => 'post', 'data-pjax' => 0])]]);
?>
    <?php 
echo GridView::widget(['id' => 'tenant-gridview', 'dataProvider' => new ActiveDataProvider(['query' => $tenantQuery, 'pagination' => ['pageSize' => 10]]), 'columns' => Tenant::column()->nameWithLink()->users()->actions()->all()]);
?>

    <?php 
Portlet::end();
?>
    <?php 
//Pjax::end();
?>
    </div>
    <!-- END tenant portlet -->

<?php 
Pjax::end();
?>
</div>