<li class="dropdown user user-menu"> <a href="#" class="dropdown-toggle" data-toggle="dropdown"> <img src="<?php echo \plathir\user\common\helpers\UserHelper::getProfileImage(Yii::$app->user->identity->id, $this); ?> " class="user-image" alt="User Image"/> <span class="hidden-xs"><?php echo Yii::$app->user->identity->username; ?> </span> </a> <ul class="dropdown-menu"> <!-- User image --> <li class="user-header"> <img src="<?php echo \plathir\user\common\helpers\UserHelper::getProfileImage(Yii::$app->user->identity->id, $this); ?> " class="img-circle" alt="User Image"/> <p> <?php echo '(' . Yii::$app->user->identity->username . ')'; ?> <?php echo \plathir\user\common\helpers\UserHelper::getProfileFullName(Yii::$app->user->identity->id); ?> <small>Member since <?php echo Yii::$app->formatter->asDatetime(Yii::$app->user->identity->created_at); ?> </small>
$roles_html .= '</tbody> </table>'; } $items[] = ['label' => '<span class="glyphicon glyphicon-user" aria-hidden="true"></span> Account', 'encode' => false, 'content' => '<br>' . Html::button('<span class="glyphicon glyphicon-edit" aria-hidden="true"></span> Account Edit', ['value' => Url::to(['edit']), 'class' => 'btn btn-success', 'id' => 'modalButtonAccount']) . '  ' . Html::button('<span class="glyphicon glyphicon-edit" aria-hidden="true"></span> Change Password', ['value' => Url::to(['change-password']), 'class' => 'btn btn-danger', 'id' => 'modalButtonChangePass']) . '<br><br>' . $account_html]; $items[] = ['label' => '<span class="glyphicon glyphicon-th-list" aria-hidden="true"></span> Profile', 'encode' => false, 'content' => '<br>' . $profile_html, 'options' => ['id' => 'profileTab']]; $items[] = ['label' => '<span class="glyphicon glyphicon-flag" aria-hidden="true"></span> Roles', 'encode' => false, 'content' => '<br>' . $roles_html, 'options' => ['id' => 'rolesTab']]; $items[] = ['label' => '<span class="glyphicon glyphicon-flag" aria-hidden="true"></span> Social', 'encode' => false, 'content' => '<br>' . $social_html, 'options' => ['id' => 'socialTab']]; $items[] = ['label' => '<span class="glyphicon glyphicon-cog" aria-hidden="true"></span> Settings', 'encode' => false, 'content' => '<br>' . $settings_html, 'options' => ['id' => 'settingsTab']]; ?> <div class="panel panel-default"> <!-- Default panel contents --> <div class="panel-heading"> <?php echo Html::img(UserHelper::getProfileImage(Yii::$app->user->identity->id, $this), ['alt' => '...', 'class' => 'img-circle', 'width' => '100', 'align' => 'center']); ?> </div> <div class="panel-body"> <p><b><?php echo '(' . Yii::$app->user->identity->username . ')'; ?> <?php echo UserHelper::getProfileFullName(Yii::$app->user->identity->id); ?> </b></p> </div> <!-- List group -->
</div> <div class="panel-body"> <div class="user-account-index"> <p> <?php echo Html::a(Yii::t('app', 'Create User'), ['create'], ['class' => 'btn btn-success']); ?> <?php echo Html::a(Yii::t('app', 'Settings'), ['/user/settings'], ['class' => 'btn btn-success']); ?> </p> <?php ?> <?php echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'columns' => [['header' => 'Image', 'format' => 'raw', 'value' => function ($model, $key, $index, $grid) { return Html::img(UserHelper::getProfileImage($model->id, $this), ['alt' => '...', 'class' => 'img-circle', 'width' => '30', 'align' => 'center']); }], 'id', 'username', ['format' => 'raw', 'value' => function ($model, $key, $index, $grid) { return Html::decode(UserHelper::getProfileFullName($model->id)); }], 'email', ['attribute' => 'status', 'value' => function ($model, $key, $index, $widget) { return $model->status == true ? '<span class="label label-success">Active</span>' : '<span class="label label-danger">Inactive</span>'; }, 'format' => 'html', 'filter' => \yii\bootstrap\Html::activeDropDownList($searchModel, 'status', ['0' => 'Inactive', '10' => 'Active'], ['class' => 'form-control', 'prompt' => 'Select...']), 'contentOptions' => ['style' => 'width: 10%;']], 'created_at:datetime', 'updated_at:datetime', ['class' => 'yii\\grid\\ActionColumn', 'contentOptions' => ['style' => 'min-width: 70px;']]]]); ?> </div> </div> </div>
<?php use plathir\user\common\helpers\UserHelper; ?> <aside class="main-sidebar"> <section class="sidebar"> <!-- Sidebar user panel --> <div class="user-panel"> <div class="pull-left image"> <img src="<?php echo UserHelper::getProfileImage(Yii::$app->user->identity->id, $this); ?> " class="img-circle" alt="User Image"/> </div> <div class="pull-left info"> <p><?php echo UserHelper::getProfileFullName(Yii::$app->user->identity->id); ?> </p> <a href="#"><i class="fa fa-circle text-success"></i> Online</a> </div> </div> <!-- search form --> <form action="#" method="get" class="sidebar-form"> <div class="input-group"> <input type="text" name="q" class="form-control" placeholder="Search..."/> <span class="input-group-btn">
$items[] = ['label' => '<span class="glyphicon glyphicon-user" aria-hidden="true"></span> Account', 'encode' => false, 'content' => '<br>' . Html::a(Yii::t('app', '<span class="glyphicon glyphicon-edit" aria-hidden="true"></span> Update User'), ['update', 'id' => $account->id], ['class' => 'btn btn-success']) . ' ' . Html::a(Yii::t('app', '<span class="glyphicon glyphicon-trash" aria-hidden="true" ></span> Delete User'), ['delete', 'id' => $account->id], ['class' => 'btn btn-danger', 'data-method' => 'post', 'data-confirm' => Yii::t('yii', 'Are you sure you want to delete this item?')]) . ' ' . Html::a(Yii::t('app', '<span class="glyphicon glyphicon-edit" aria-hidden="true"></span> Reset Password'), ['reset-password', 'id' => $account->id], ['class' => 'btn btn-warning']) . ' ' . Html::a(Yii::t('app', '<span class="glyphicon glyphicon-edit" aria-hidden="true"></span> Set Password'), ['set-password', 'id' => $account->id], ['class' => 'btn btn-primary']) . ' ' . '<br><br>' . $user_html, 'options' => ['id' => 'AccountTab']]; $items[] = ['label' => '<span class="glyphicon glyphicon-th-list" aria-hidden="true"></span> Profile', 'encode' => false, 'content' => $profile_html, 'options' => ['id' => 'ProfileTab']]; $items[] = ['label' => '<span class="glyphicon glyphicon-flag" aria-hidden="true"></span> Roles', 'encode' => false, 'content' => '<br>' . Html::a(Yii::t('app', '<span class="glyphicon glyphicon-edit" aria-hidden="true"></span> Update Roles for user'), ['/admin/assignment/view', 'id' => $account->id], ['class' => 'btn btn-success']) . ' ' . '<br><br>' . $roles_html, 'options' => ['id' => 'rolesTab']]; ?> <div class="row"> <div class="col-md-3 col-sm-6 col-xs-12"> <div class="text-center"> <?php $bundle = userAsset::register($this); ?> <div class="panel panel-default"> <!-- Default panel contents --> <div class="panel-heading"> <?php echo Html::img(UserHelper::getProfileImage($account->id, $this), ['alt' => '...', 'class' => 'img-circle', 'width' => '100', 'align' => 'center']); ?> </div> <div class="panel-body"> <p><b><?php echo '(' . $account->username . ')'; ?> <?php echo UserHelper::getProfileFullName($account->id); ?> </b></p> </div> <!-- List group -->
<div class="box box-danger"> <div class="box-header with-border"> <h3 class="box-title">Latest Members</h3> <div class="box-tools pull-right"> <button class="btn btn-box-tool" data-widget="collapse"><i class="fa fa-minus"></i></button> <button class="btn btn-box-tool" data-widget="remove"><i class="fa fa-times"></i></button> </div> </div><!-- /.box-header --> <div class="box-body no-padding"> <ul class="users-list clearfix"> <?php foreach ($LatestUsers as $user) { ?> <li> <img src="<?php echo UserHelper::getProfileImage($user['id'], $this); ?> "User Image"> <a class="users-list-name" <?php echo Html::a($user['username'], ['/user/admin/view', 'id' => $user['id']]); ?> </a> <span class="users-list-date"><?php echo Yii::$app->formatter->asDate($user['created_at']); ?> </span> </li> <?php } ?> <li>