Exemple #1
0
 public function changeItem(&$item)
 {
     if (isset($item['glyphicon'])) {
         $item['label'] = Html::glyphicon($item['glyphicon']) . $item['label'];
         $item['encode'] = false;
     }
 }
Exemple #2
0
?>
                    </div>
                </div>
                <div class="form-group">
                    <label><?php 
echo $widget->t('IMAGE');
?>
:</label>
                    <br>
                    <img src="<?php 
echo $formModel->mid_src;
?>
" id="uploaded_image">
                    <br>
                    <button class="btn btn-danger btn-xs bCancelUpload bOnlyIcon"><?php 
echo Html::glyphicon('remove');
?>
</button>
                </div>
                
                <?php 
echo $form->field($formModel, 'upload_key')->hiddenInput(['id' => 'upload_key'])->label('');
?>
                <iframe name="fUpload" style="display: none;"></iframe>
                
                <div class="form-group text-right">
                    <?php 
echo Html::cancelButton(['url' => $urlToCancel]);
?>
                    <?php 
echo Html::saveButton();
Exemple #3
0
$controller = $this->context;
$request = \Yii::$app->request;
$listUrl = [$controller::URL_TO_INDEX];
$title = $controller->t('USER {login}', ['login' => Html::encode($model->login)]);
$urlToDelete = [$controller::URL_TO_DELETE, 'id' => $model->id, $request->csrfParam => $request->getCsrfToken()];
$this->params['breadcrumbs'] = [['label' => $controller->t($controller::TITLE), 'url' => [$controller::URL_TO_INDEX]], ['label' => $controller->t('SHOW_USER')]];
?>

<br>
<?php 
echo Html::listButton(['url' => $listUrl, 'text' => $controller->t('LIST_USERS')]);
?>

<h1>
    <?php 
echo Html::glyphicon('user');
?>
    <?php 
echo $title;
?>
</h1>
<div class="row detail-view-complex">
    <div class="col-xs-6">
        <?php 
echo DetailView::widget(['model' => $model, 'attributes' => ['id', 'login', ['attribute' => 'enabled', 'value' => $model->formatEnabled()], ['attribute' => 'groups', 'value' => $model->formatGroups()], 'created_dt']]);
?>
        
        <div class="buttons">
            <?php 
echo Html::deleteButton(['url' => $urlToDelete]);
?>
Exemple #4
0
<?php

use yii\widgets\ListView;
use app\helpers\Html;
$controller = $this->context;
$this->params['breadcrumbs'] = [['label' => $controller->t($controller::TITLE)]];
$this->title = [$controller->t($controller::TITLE)];
?>
<h1>
    <?php 
echo Html::glyphicon('picture');
?>
    <?php 
echo $controller->t($controller::TITLE);
?>
</h1>

<?php 
echo Html::addButton(['url' => $controller::URL_TO_ADD]);
?>
<br><br>

<?php 
echo ListView::widget(['dataProvider' => $DP, 'itemView' => '_list_item.php', 'options' => ['class' => 'list-view list-view-linear list-view-images'], 'layout' => '{items}<div class="pagination-wrap">{pager}</div>', 'itemOptions' => ['tag' => false]]);
Exemple #5
-1
 public function init()
 {
     if ($this->brandGlyphicon) {
         $this->brandLabel = Html::glyphicon($this->brandGlyphicon) . $this->brandLabel;
     }
     parent::init();
 }