Esempio n. 1
0
 public function registerAssets()
 {
     $view = Yii::$app->getView();
     userAsset::register($view);
 }
Esempio n. 2
0
        <tbody>';
    foreach ($roles as $role) {
        $roles_html .= '<tr><td>' . $role->name . '</td><td>' . $role->description . '</td></tr>';
    }
    $roles_html .= '</tbody>
    </table>';
}
$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']) . '&nbsp' . 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?')]) . '&nbsp' . 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']) . '&nbsp' . 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']) . '&nbsp' . '<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']) . '&nbsp' . '<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 . ')';
?>