update thống kê

This commit is contained in:
2020-10-16 11:35:29 +07:00
parent 53de75104e
commit 4ba094ab24
16 changed files with 526 additions and 80 deletions

View File

@@ -4,41 +4,42 @@
{use class="app\assets\UserAsset"}
{UserAsset::register($this)|void}
{block name='content'}
<div class="text-left">
<button class="btn btn-primary" onclick="common.form(this, 'user');" data-href="{Url::to(['create'])}">
<i class="fa fa-plus"></i> Thêm mới
</button>
</div>
<br>
{GridView::widget([
'dataProvider' => $dataProvider,
'filterModel' => $searchModel,
'layout'=> \app\helpers\UserGrid::getLayout(),
'tableOptions' => [
'class' => 'table table-striped table-bordered',
'style' => 'background:#fff;min-width:700px;'
],
'columns' => [
['class' => 'yii\grid\SerialColumn'],
'username',
'first_name',
[
'attribute' => 'roleName',
'format' => 'raw',
'value' => \app\helpers\UserGrid::roles()
<div class="logs-index">
<div class="" style="font-size: 15px;">
<label class="action-button" onclick="common.form(this, 'user');" data-href="{Url::to(['create'])}">
<i class="fa fa-plus-square fa-1-5x"></i> Thêm
</label>
</div>
{GridView::widget([
'dataProvider' => $dataProvider,
'filterModel' => $searchModel,
'layout'=> \app\helpers\UserGrid::getLayout(),
'tableOptions' => [
'class' => 'table table-striped table-bordered',
'style' => 'background:#fff;min-width:700px;'
],
'phone_number',
'email',
[
'template'=> \app\helpers\UserGrid::actionTemplate(),
'class' => 'yii\grid\ActionColumn',
'contentOptions' => ['class' => 'text-center'],
'headerOptions' => ['style' => 'width:10%'],
'buttons' => [
'update' => \app\helpers\UserGrid::update('user'),
'delete' => \app\helpers\UserGrid::delete('Bạn có chắc chắn muốn xóa người dùng này không?')
'columns' => [
['class' => 'yii\grid\SerialColumn'],
'username',
'first_name',
[
'attribute' => 'roleName',
'format' => 'raw',
'value' => \app\helpers\UserGrid::roles()
],
'phone_number',
'email',
[
'template'=> \app\helpers\UserGrid::actionTemplate(),
'class' => 'yii\grid\ActionColumn',
'contentOptions' => ['class' => 'text-center'],
'headerOptions' => ['style' => 'width:10%'],
'buttons' => [
'update' => \app\helpers\UserGrid::update('user'),
'delete' => \app\helpers\UserGrid::delete('Bạn có chắc chắn muốn xóa người dùng này không?')
]
]
]
]
])}
])}
</div>
{/block}