Exemplo n.º 1
0
        </div>
    </form>
</div>
<a href="#" id="btn_sql">ชุดคำสั่ง</a>
<div id="sql" style="display: none"><?php 
echo '';
?>
</div>

    <?php 
if (isset($dataProvider)) {
    $dev = Html::a('คุณอุเทน จาดยางโทน', 'https://fb.com/tehnn', ['target' => '_blank']);
    $y = $selyear + 543;
    $y = substr($y, 2, 2);
    $py = $y - 1;
    echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['attribute' => 'hoscode', 'label' => ''], ['attribute' => 'hosname', 'label' => 'สถานบริการ'], ['attribute' => 'oct', 'label' => "ตค" . $py . "(คน)"], ['attribute' => 'oct1', 'label' => "ตค" . $py . "(ครั้ง)"], ['attribute' => 'nov', 'label' => "พย" . $py . "(คน)"], ['attribute' => 'nov1', 'label' => "พย" . $py . "(ครั้ง)"], ['attribute' => 'dec', 'label' => "ธค" . $py . "(คน)"], ['attribute' => 'dec1', 'label' => "ธค" . $py . "(ครั้ง)"], ['attribute' => 'jan', 'label' => "มค" . $y . "(คน)"], ['attribute' => 'jan1', 'label' => "มค" . $y . "(ครั้ง)"], ['attribute' => 'feb', 'label' => "กพ" . $y . "(คน)"], ['attribute' => 'feb1', 'label' => "กพ" . $y . "(ครั้ง)"], ['attribute' => 'mar', 'label' => "มีค" . $y . "(คน)"], ['attribute' => 'mar1', 'label' => "มีค" . $y . "(ครั้ง)"], ['attribute' => 'apr', 'label' => "เมย" . $y . "(คน)"], ['attribute' => 'apr1', 'label' => "เมย" . $y . "(ครั้ง)"], ['attribute' => 'may', 'label' => "พค" . $y . "(คน)"], ['attribute' => 'may1', 'label' => "พค" . $y . "(ครั้ง)"], ['attribute' => 'jun', 'label' => "มิย" . $y . "(คน)"], ['attribute' => 'jun1', 'label' => "มิย" . $y . "(ครั้ง)"], ['attribute' => 'jul', 'label' => "กค" . $y . "(คน)"], ['attribute' => 'jul1', 'label' => "กค" . $y . "(ครั้ง)"], ['attribute' => 'aug', 'label' => "สค" . $y . "(คน)"], ['attribute' => 'aug1', 'label' => "สค" . $y . "(ครั้ง)"], ['attribute' => 'sep', 'label' => "กย" . $y . "(คน)"], ['attribute' => 'sep1', 'label' => "กย" . $y . "(ครั้ง)"]]]);
}
?>

<?php 
$script = <<<JS
\$('#btn_sql').on('click', function(e) {
    
   \$('#sql').toggle();
});
JS;
$this->registerJs($script);
?>


Exemplo n.º 2
0
</div>

<div class="form-actions">
<?php 
echo \yii\helpers\Html::submitButton(Yii::t('app', 'Deposit'), ['class' => 'btn btn-success']);
?>


    <div id ="result">

        <?php 
//echo app\widgets\GridView::widget( array(
echo yii\grid\GridView::widget(array('id' => 'depsoit-grid', 'dataProvider' => $cheques->depositSearch(), 'columns' => array(array('value' => function ($data) {
    return \yii\helpers\Html::checkBox("FormDeposit[Deposit][{$data->doc_id},{$data->line}]", false, ['id' => 'FormDeposit_Deposit-' . $data->doc_id . "_" . $data->line]) . \yii\helpers\Html::hiddenInput("FormDeposit[Total][{$data->doc_id},{$data->line}]", "{$data->sum}", ['id' => 'FormDeposit_Total-' . $data->doc_id . "_" . $data->line]) . \yii\helpers\Html::hiddenInput("FormDeposit[Type][{$data->doc_id},{$data->line}]", "{$data->type}", ['id' => 'FormDeposit_Type-' . $data->doc_id . "_" . $data->line]);
}, 'filter' => '', 'format' => 'raw'), array('attribute' => 'type', 'value' => function ($data) {
    return Yii::t("app", $data->typeo->name);
}), array('value' => function ($data) {
    return $data->printDetails();
}), 'currency_id', 'sum', array('class' => 'yii\\grid\\ActionColumn'))));
?>

            </div>
            <div id="sum">
            </div>
        </div>
        <?php 
kartik\form\ActiveForm::end();
?>

        <?php 
app\widgets\MiniForm::end();
Exemplo n.º 3
0
<?php

use yii\helpers\Html;
use yii\helpers\Url;
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => ['name', 'lname', ['class' => 'yii\\grid\\ActionColumn', 'header' => 'การปฏิบัติ', 'template' => '{new_action1} {new_action2}', 'headerOptions' => ['class' => 'text-center'], 'contentOptions' => ['class' => 'text-center'], 'buttons' => ['new_action1' => function ($url, $model) {
    return Html::a('<span id="btn1" class="glyphicon glyphicon-check" data-toggle="tooltip" data-placement="left" title="Check"></span>', $url, ['data' => ['confirm' => 'Are you sure do it?']]);
}, 'new_action2' => function ($url, $model) {
    return Html::a('<span id="btn2" class="glyphicon glyphicon-remove" data-toggle="tooltip" data-placement="left" title="Remove"></span>', $url, ['data' => ['confirm' => 'Are you sure do it?', 'method' => 'post']]);
}], 'urlCreator' => function ($action, $model, $key, $index) {
    if ($action === 'new_action1') {
        $url = Url::to(['controller_name/action_name', 'id' => $model['id']]);
        return $url;
    } elseif ($action === 'new_action2') {
        $url = Url::to(['json', 'id' => $model['id']]);
        return $url;
    }
}]]]);
Exemplo n.º 4
0
    </div>
</div>

<a href="#" id="btn_sql">ชุดคำสั่ง</a>
<div id="sql" style="display: none"><?php 
echo '';
?>
</div>

<?php 
if (isset($dataProvider)) {
    $dev = Html::a('คุณอุเทน จาดยางโทน', 'https://fb.com/tehnn', ['target' => '_blank']);
    $y = $selyear + 543;
    $y = substr($y, 2, 2);
    $py = $y - 1;
    echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['attribute' => 'hoscode', 'label' => 'รหัส'], ['attribute' => 'hosname', 'label' => 'สถานบริการ'], ['attribute' => 'p_all', 'header' => "ประชากรทั้งหมด<br>(คน)"], ['attribute' => 'men', 'header' => "ชาย<br>(คน)"], ['attribute' => 'women', 'header' => "หญิง<br>(คน)"], ['attribute' => '<1y', 'header' => "ต่ำกว่า 1 ปี<br>(คน)"], ['attribute' => '1-5y', 'header' => "1-5 ปี<br>(คน)"], ['attribute' => '6-12y', 'header' => "6-12 ปี<br>(คน)"], ['attribute' => '13-59y', 'header' => "13-59 ปี<br>(คน)"], ['attribute' => '>=60y', 'header' => "60 ปี ขึ้นไป<br>(คน)"]]]);
}
?>

<?php 
$script = <<<JS
\$('#btn_sql').on('click', function(e) {
    
   \$('#sql').toggle();
});
JS;
$this->registerJs($script);
?>


Exemplo n.º 5
0
            <?php 
echo DetailView::widget(['options' => ['class' => 'table table-striped detail-view', 'style' => 'padding:0px;'], 'model' => $model, 'attributes' => ['transfer_num', 'idWarehouseSource.nm_whse', 'idWarehouseDest.nm_whse', 'transferDate', 'nmStatus']]);
?>
        </div>
        <div class="box-footer">
            <?php 
if ($model->status == Transfer::STATUS_DRAFT) {
    echo Html::a('Update', ['update', 'id' => $model->id_transfer], ['class' => 'btn btn-primary']) . ' ';
    echo Html::a('Delete', ['delete', 'id' => $model->id_transfer], ['class' => 'btn btn-danger', 'data-confirm' => Yii::t('app', 'Are you sure to delete this item?'), 'data-method' => 'post']) . ' ';
    echo Html::a('Issue', ['issue', 'id' => $model->id_transfer], ['class' => 'btn btn-primary', 'data-confirm' => Yii::t('app', 'Are you sure to issue this item?'), 'data-method' => 'post']);
}
if ($model->status == Transfer::STATUS_CONFIRM) {
    echo Html::a('Approve', ['confirm', 'confirm' => Transfer::STATUS_CONFIRM_APPROVE, 'id' => $model->id_transfer], ['class' => 'btn btn-primary', 'data-confirm' => Yii::t('app', 'Are you sure to approve this item?'), 'data-method' => 'post']) . ' ';
    echo Html::a('Reject', ['confirm', 'confirm' => Transfer::STATUS_CONFIRM_REJECT, 'id' => $model->id_transfer], ['class' => 'btn btn-primary', 'data-confirm' => Yii::t('app', 'Are you sure to reject this item?'), 'data-method' => 'post']);
}
?>
        </div>
    </div>
</div>
<div class="purchase-hdr-view col-lg-9">
    <div class="box box-info">
        <div class="box-body no-padding">
            <?php 
echo yii\grid\GridView::widget(['tableOptions' => ['class' => 'table table-striped'], 'layout' => '{items}{pager}', 'dataProvider' => new \yii\data\ActiveDataProvider(['query' => $model->getTransferDtls(), 'sort' => false, 'pagination' => false]), 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'idProduct.cd_product', 'idProduct.nm_product', 'transfer_qty_send', 'transfer_qty_receive', ['header' => 'Selisih', 'value' => function ($model) {
    return $model->transfer_qty_receive - $model->transfer_qty_send;
}], 'idUom.nm_uom']]);
?>
        </div>
    </div>
</div>
Exemplo n.º 6
0
/* @var $this yii\web\View */
/* @var $model Sales */
/* @var $grModel GoodsMovement */
$this->title = $model->number;
$this->params['breadcrumbs'][] = ['label' => 'Sales', 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
?>

<h1><?php 
echo Html::encode($this->title);
?>
</h1>

<div class="col-lg-12" style="padding-left: 0px;">
    <div class="panel panel-primary">
        <?php 
echo DetailView::widget(['options' => ['class' => 'table table-striped detail-view', 'style' => 'padding:0px;'], 'model' => $model, 'attributes' => ['number', 'nmSupplier', 'Date', 'value', 'nmStatus']]);
?>
    </div>
</div>
<div class="col-lg-12">
    <?php 
echo yii\grid\GridView::widget(['tableOptions' => ['class' => 'table table-striped'], 'layout' => '{items}', 'dataProvider' => $dataProvider, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'number', 'date']]);
?>
</div>
<?php 
if ($grModel->status == GoodsMovement::STATUS_OPEN) {
    echo $this->render('_gr_edit', ['model' => $model, 'grModel' => $grModel]);
} else {
    echo $this->render('_gr_view', ['model' => $model, 'grModel' => $grModel]);
}
Exemplo n.º 7
0
 * Панель управления книгами.
 */
use yii\helpers\Html;
$this->title = 'CRUD Author';
?>

<h1>Управление авторами</h1>

<p>
    <a class="btn btn-primary" href="<?php 
echo yii\helpers\Url::to(['back-author/create']);
?>
">Добавить</a>
</p>

<hr>

<?php 
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $modelAuthor, 'columns' => ['id', 'name', ['attribute' => 'description', 'value' => function ($modelAuthor) {
    /** @var app\models\Author $modelAuthor */
    return \yii\helpers\BaseStringHelper::truncateWords($modelAuthor->description, 10);
}], ['attribute' => 'photo', 'format' => 'html', 'value' => function ($modelAuthor) {
    /** @var app\models\Author $modelAuthor */
    return $modelAuthor->photo ? Html::img($modelAuthor->photo) : '';
}], ['format' => 'html', 'label' => 'Опции', 'value' => function ($modelAuthor) {
    /** @var app\models\Author $modelAuthor */
    return Html::a('Просмотреть', ['back-author/view', 'id' => $modelAuthor->id], ['class' => 'btn btn-default']) . ' ' . Html::a('Изменить', ['back-author/update', 'id' => $modelAuthor->id], ['class' => 'btn btn-default']) . ' ' . Html::a('Удалить', ['back-author/delete', 'id' => $modelAuthor->id], ['class' => 'btn btn-danger']);
}]]]);
?>

Exemplo n.º 8
0
 * The Original Code is:  Linet 3.0 Open Source
 * The Initial Developer of the Original Code is Adam Ben Hur.
 * All portions are Copyright (C) Adam Ben Hur.
 * All Rights Reserved.
 ************************************************************************************/
?>
<h3><?php 
echo Yii::t("app", "Install Wizard");
?>
: <?php 
echo Yii::t("app", "Prerequisites");
?>
</h3>
<div class="iPage">
    <?php 
echo yii\grid\GridView::widget(array('id' => 'pre-grid', 'dataProvider' => $model->report(), 'columns' => array('id', 'value')));
?>

<?php 
$form = kartik\form\ActiveForm::begin(array('id' => 'install-form', 'enableAjaxValidation' => false, 'options' => array()));
echo $form->field($model, 'step', ['template' => "{input}"])->hiddenInput();
?>
    <div class="form-actions">
        <?php 
echo \yii\helpers\Html::submitButton(Yii::t("app", 'Next'), ['class' => 'btn btn-success']);
?>
    </div>
<?php 
kartik\form\ActiveForm::end();
?>
Exemplo n.º 9
0
use yii\helpers\Html;
use app\models\User;
$this->title = \Yii::t('app', 'Search Panel - List of uploaded records');
$clearLabel = \Yii::t('app', 'Clear Filters');
?>

<div class="user-index">

    <div class="white-background">

        <?php 
yii\widgets\Pjax::begin(['id' => 'pjax-frontend-search', 'timeout' => false, 'enablePushState' => false, 'formSelector' => '#form-record-search-filter']);
?>
        <?php 
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['label' => '#', 'attribute' => 'id'], ['attribute' => 'infraction_date', 'format' => 'date'], ['label' => 'Vehicle Tag #', 'attribute' => 'license'], ['label' => 'Uploaded Date', 'attribute' => 'created_at', 'format' => 'date'], ['label' => 'Uploaded By', 'attribute' => 'fullName'], ['label' => 'Elapsed time, days', 'attribute' => 'elapsedTime'], ['class' => \yii\grid\ActionColumn::className(), 'template' => '{review}', 'buttons' => ['review' => function ($url, $model) {
    return \yii\helpers\Html::a('<span class="glyphicon glyphicon-eye-open"></span>', \yii\helpers\Url::to(['review', 'id' => $model->id]), ['title' => Yii::t('app', 'Review'), 'data-pjax' => '0']);
}]]]]);
yii\widgets\Pjax::end();
?>
    </div>

    <?php 
$this->registerJs('$("document").ready(function(){
        $("#pjax-frontend-search").on("pjax:start", function() {
            $("#pjax-frontend-search").addClass("page-loading");
        });

        $("#pjax-frontend-search").on("pjax:end", function() {
            $("#pjax-frontend-search").removeClass("page-loading");
        });
Exemplo n.º 10
0
                <button class='btn btn-danger'>ประมวลผล</button>
            </div>
        </div>
    </form>
</div>

<a href="#" id="btn_sql">ชุดคำสั่ง</a>
<div id="sql" style="display: none"><?php 
echo $sql;
?>
</div>

    <?php 
if (isset($dataProvider)) {
    $dev = Html::a('คุณนครินทร์ เกตุวีระพงศ์', 'https://fb.com/nakharin.knott', ['target' => '_blank']);
    $y = $selyear + 543;
    $y = substr($y, 2, 2);
    $py = $y - 1;
    echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], ['attribute' => 'hoscode', 'header' => 'รหัส'], ['attribute' => 'hosname', 'label' => 'สถานบริการ'], ['attribute' => 'm10_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>ต.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm10_panth_drug', 'header' => 'ยาแผนไทย<br>ต.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm11_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>พ.ย.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm11_panth_drug', 'header' => 'ยาแผนไทย<br>พ.ย.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm12_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>ธ.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm12_panth_drug', 'header' => 'ยาแผนไทย<br>ธ.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm01_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>ม.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm01_panth_drug', 'header' => 'ยาแผนไทย<br>ม.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm02_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>ก.พ.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm02_panth_drug', 'header' => 'ยาแผนไทย<br>ก.พ.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm03_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>มี.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm03_panth_drug', 'header' => 'ยาแผนไทย<br>มี.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm04_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>เม.ย.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm04_panth_drug', 'header' => 'ยาแผนไทย<br>เม.ย.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm05_price_drug', 'header' => 'ยาแผนปัจจุบัน<br>พ.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm05_panth_drug', 'header' => 'ยาแผนไทย <br>พ.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm06_price_drug', 'header' => 'ยาแผนปัจจุบัน <br>มิ.ย.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm06_panth_drug', 'header' => 'ยาแผนไทย <br>มิ.ย.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm07_price_drug', 'header' => 'ยาแผนปัจจุบัน <br>ก.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm07_panth_drug', 'header' => 'ยาแผนไทย <br>ก.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm08_price_drug', 'header' => 'ยาแผนปัจจุบัน <br>ส.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm08_panth_drug', 'header' => 'ยาแผนไทย <br>ส.ค.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm09_price_drug', 'header' => 'ยาแผนปัจจุบัน <br>ก.ย.<br>(บาท)', 'format' => ['decimal', 2]], ['attribute' => 'm09_panth_drug', 'header' => 'ยาแผนไทย <br>ก.ย.<br>(บาท)', 'format' => ['decimal', 2]]]]);
}
?>

<?php 
$script = <<<JS
\$('#btn_sql').on('click', function(e) {
    
   \$('#sql').toggle();
});
JS;
$this->registerJs($script);
Exemplo n.º 11
0
<?php

use yii\helpers\Html;
use yii\widgets\DetailView;
echo DetailView::widget(['model' => $model, 'attributes' => ['id', 'create_uid', 'create_date', 'write_date', 'product_qty', 'picking_id']]);
?>


<?php 
echo Html::a('<span class="glyphicon glyphicon-eye-open"></span>', Yii::$app->urlManager->createUrl(['moves/generate-product-set', 'id' => $model->id, 'product_id' => $model->product_id]));
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $filterModel, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'id', 'picking_id', 'product_uom', 'product_uos_qty', 'product_qty', 'name', 'product_id']]);
?>


Exemplo n.º 12
0
<div class="mrp-bom-view">

    <h1><?php 
echo Html::encode($this->title);
?>
</h1>

    <p>
        <?php 
echo Html::a('Update', ['update', 'id' => $model->id], ['class' => 'btn btn-primary']);
?>
        <?php 
echo Html::a('Delete', ['delete', 'id' => $model->id], ['class' => 'btn btn-danger', 'data' => ['confirm' => 'Are you sure you want to delete this item?', 'method' => 'post']]);
?>
    </p>

    <?php 
echo DetailView::widget(['model' => $model, 'attributes' => ['id', 'product_qty', 'product_efficiency', 'name', 'product.name_template', 'type']]);
?>

    <?php 
echo yii\grid\GridView::widget(['dataProvider' => $moves['dataProvider'], 'filterModel' => $moves['searchModel'], 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'id', 'picking_id', 'product_uom', 'product_uos_qty', 'product_qty', 'name', 'product_id', ['header' => 'Childs', 'value' => function ($data) {
    $check = app\models\StockMove::find()->where(['move_dest_id' => $data->id])->count();
    return $check;
}], ['class' => 'yii\\grid\\ActionColumn', 'buttons' => ['view' => function ($url, $model, $Key) {
    return Html::a('<span class="glyphicon glyphicon-eye-open"></span>', Yii::$app->urlManager->createUrl(['moves/view-move-childs', 'id' => $model->id]));
}]]]]);
?>
    
</div>
Exemplo n.º 13
0
//                ),
//            ));
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], ['label' => 'PARTIDA PRESUPUESTARIA', 'format' => 'raw', 'value' => function ($data) {
    return Html::label(trim($data->categoria) . trim($data->puc));
}], ['label' => 'DESCRIPCION DE PARTIDA', 'format' => 'raw', 'value' => function ($data) {
    if (trim($data->descripcionaux) != "") {
        return Html::label(trim($data->descripcionaux));
    } else {
        $cuenta = Cuenta::find()->where("puc like '%" . trim($data->puc) . "%'")->andWhere("categoria like '%" . trim($data->categoria) . "%'")->one();
        if ($cuenta) {
            return Html::label(trim($cuenta->descripcion));
        } else {
            $puc = app\models\Puc::find()->where("puc like '%" . trim($data->puc) . "%'")->one();
            if ($puc) {
                return Html::label(trim($puc->descripcion));
            } else {
                return Html::label("N/A");
            }
        }
    }
}], ['label' => 'COMPROMETIDO ACTUAL', 'format' => 'raw', 'value' => function ($data) {
    return '<div class="input-group">' . Html::input("text", "beneficiario", $data->comprometido, ['class' => 'form-control', 'readonly' => 'readonly']) . '<span class="input-group-addon">Bs</span>.</div>';
}], ['label' => 'AJUSTE', 'format' => 'raw', 'value' => function ($data) {
    return '<div class="input-group">' . Html::input("numeric", "ajuste", "0", ['class' => 'form-control']) . '<span class="input-group-addon">Bs</span>.</div>';
}], ['label' => 'NUEVO COMPROMETIDO', 'format' => 'raw', 'value' => function ($data) {
    return '<div class="input-group">' . Html::input("text", "nuevoComprometido", "", ['class' => 'form-control', 'readonly' => 'readonly']) . '<span class="input-group-addon">Bs</span>.</div>';
}], ['label' => 'DISPONIBILIDAD', 'format' => 'raw', 'value' => function ($data) {
    return '<div class="input-group">' . Html::input("text", "disponibilidad", $data->disponibilidad, ['class' => 'form-control', 'readonly' => 'readonly']) . '<span class="input-group-addon">Bs</span>.</div>';
}]]]);
?>
    </div>
Exemplo n.º 14
0
                <button class='btn btn-danger'>ประมวลผล</button>
            </div>
        </div>
    </form>
</div>

<a href="#" id="btn_sql">ชุดคำสั่ง</a>
<div id="sql" style="display: none"><?php 
echo $sql;
?>
</div>

    <?php 
if (isset($dataProvider)) {
    $dev = Html::a('คุณนครินทร์ เกตุวีระพงศ์', 'https://fb.com/nakharin.knott', ['target' => '_blank']);
    $y = $selyear + 543;
    $y = substr($y, 2, 2);
    $py = $y - 1;
    echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], ['attribute' => 'hospcode', 'header' => 'รหัส'], ['attribute' => 'hosname', 'label' => 'สถานบริการ'], ['attribute' => 'instype', 'label' => 'สิทธิรักษา'], ['attribute' => 'pt_all', 'header' => 'รับบริการ<br>ทั้งหมด<br>(คน)'], ['attribute' => 'service_all', 'header' => 'รับบริการ<br>ทั้งหมด<br>(ครั้ง)'], ['attribute' => 'pt_m10', 'header' => 'รับบริการ<br>ต.ค.<br>(คน)'], ['attribute' => 'service_m10', 'header' => 'รับบริการ<br>ต.ค.<br>(ครั้ง)'], ['attribute' => 'pt_m11', 'header' => 'รับบริการ<br>พ.ย.<br>(คน)'], ['attribute' => 'service_m11', 'header' => 'รับบริการ<br>พ.ย.<br>(ครั้ง)'], ['attribute' => 'pt_m12', 'header' => 'รับบริการ<br>ธ.ค.<br>(คน)'], ['attribute' => 'service_m12', 'header' => 'รับบริการ<br>ธ.ค.<br>(ครั้ง)'], ['attribute' => 'pt_m01', 'header' => 'รับบริการ<br>ม.ค.<br>(คน)'], ['attribute' => 'service_m01', 'header' => 'รับบริการ<br>ม.ค.<br>(ครั้ง)'], ['attribute' => 'pt_m02', 'header' => 'รับบริการ<br>ก.พ.<br>(คน)'], ['attribute' => 'service_m02', 'header' => 'รับบริการ<br>ก.พ.<br>(ครั้ง)'], ['attribute' => 'pt_m03', 'header' => 'รับบริการ<br>มี.ค.<br>(คน)'], ['attribute' => 'service_m03', 'header' => 'รับบริการ<br>มี.ค.<br>(ครั้ง)'], ['attribute' => 'pt_m04', 'header' => 'รับบริการ<br>เม.ย.<br>(คน)'], ['attribute' => 'service_m04', 'header' => 'รับบริการ<br>เม.ย.<br>(ครั้ง)'], ['attribute' => 'pt_m05', 'header' => 'รับบริการ<br>พ.ค.<br>(คน)'], ['attribute' => 'service_m05', 'header' => 'รับบริการ<br>พ.ค.<br>(ครั้ง)'], ['attribute' => 'pt_m06', 'header' => 'รับบริการ<br>มิ.ย.<br>(คน)'], ['attribute' => 'service_m06', 'header' => 'รับบริการ<br>มิ.ย.<br>(ครั้ง)'], ['attribute' => 'pt_m07', 'header' => 'รับบริการ<br>ก.ค.<br>(คน)'], ['attribute' => 'service_m07', 'header' => 'รับบริการ<br>ก.ค.<br>(ครั้ง)'], ['attribute' => 'pt_m08', 'header' => 'รับบริการ<br>ส.ค.<br>(คน)'], ['attribute' => 'service_m08', 'header' => 'รับบริการ<br>ส.ค.<br>(ครั้ง)'], ['attribute' => 'pt_m09', 'header' => 'รับบริการ<br>ก.ย.<br>(คน)'], ['attribute' => 'service_m09', 'header' => 'รับบริการ<br>ก.ย.<br>(ครั้ง)']]]);
}
?>

<?php 
$script = <<<JS
\$('#btn_sql').on('click', function(e) {
    
   \$('#sql').toggle();
});
JS;
$this->registerJs($script);
Exemplo n.º 15
0
echo DetailView::widget(['options' => ['class' => 'table table-striped detail-view'], 'model' => $model, 'attributes' => ['number', 'supplier.name', 'date:date', 'value:currency', 'nmStatus']]);
?>
                <?php 
if ($model->status == Purchase::STATUS_DRAFT) {
    echo Html::a('Update', ['update', 'id' => $model->id], ['class' => 'btn btn-primary']) . ' ';
    echo Html::a('Delete', ['delete', 'id' => $model->id], ['class' => 'btn btn-danger', 'data-confirm' => Yii::t('app', 'Are you sure to delete this item?'), 'data-method' => 'post']) . ' ';
}
echo Html::a('Receive', ['receive', 'id' => $model->id], ['class' => 'btn btn-success']);
?>
            </div> 
            <div class="tab-pane" id="receives">
                Goods Receives
            </div> 
            <div class="tab-pane" id="tab_2-2">
                Shipping Cost, dll.
            </div>
        </div>
    </div>
</div>   

<div class="col-lg-12">
    <div class="box box-info">
        <div class="box-body no-padding">
            <?php 
echo yii\grid\GridView::widget(['tableOptions' => ['class' => 'table table-striped'], 'layout' => '{items}', 'dataProvider' => new \yii\data\ActiveDataProvider(['query' => $model->getPurchaseDtls(), 'sort' => false, 'pagination' => false]), 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'product.name', 'qty', 'total_receive', 'price', 'uom.name']]);
?>
        </div>
    </div>
</div>

Exemplo n.º 16
0
/**
 * @var yii\web\View $this
 * @var app\models\Tag $modelTag
 * @var yii\data\ActiveDataProvider $dataProvider
 *
 * Панель управления книгами.
 */
use yii\helpers\Html;
$this->title = 'CRUD Tag';
?>

<h1>Управление книгами</h1>

<p>
    <a class="btn btn-primary" href="<?php 
echo yii\helpers\Url::to(['back-tag/create']);
?>
">Добавить</a>
</p>

<hr>

<?php 
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $modelTag, 'columns' => ['id', 'title', 'alias', ['format' => 'html', 'label' => 'Опции', 'value' => function ($modelTag) {
    /** @var app\models\Tag $modelTag */
    return Html::a('Просмотреть', ['back-tag/view', 'id' => $modelTag->id], ['class' => 'btn btn-default']) . ' ' . Html::a('Изменить', ['back-tag/update', 'id' => $modelTag->id], ['class' => 'btn btn-default']) . ' ' . Html::a('Удалить', ['back-tag/delete', 'id' => $modelTag->id], ['class' => 'btn btn-danger']);
}]]]);
?>

Exemplo n.º 17
0
                </div>
                <div class="tab-pane col-lg-12" id="delivery-pane">
                    <div class="box box-solid">
                        <?php 
//                        echo ListView::widget([
//                            'dataProvider' => $greceipt,
//                            'layout' => '{items}',
//                            'itemView' => '_greceipt',
//                                //'options' => ['class' => 'box-body']
//                        ]);
?>
                        <?php 
echo yii\grid\GridView::widget(['tableOptions' => ['class' => 'table table-striped'], 'layout' => '{items}', 'dataProvider' => $greceipt, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], ['label' => 'Receipt Number', 'format' => 'raw', 'value' => function ($data) {
    return Html::a($data->number, ['inventory/movement/view', 'id' => $data->id]);
}], 'date:date', ['attribute' => 'warehouse_id', 'value' => 'warehouse.name', 'filter' => Warehouse::selectOptions()], ['attribute' => 'status', 'format' => 'raw', 'filter' => [GoodsMovement::STATUS_DRAFT => 'Draft', GoodsMovement::STATUS_PROCESS => 'Proccess', GoodsMovement::STATUS_CLOSE => 'Closed'], 'value' => function ($data) {
    $color = $data->status == GoodsMovement::STATUS_DRAFT ? 'danger' : 'success';
    $color = $data->status == GoodsMovement::STATUS_PROCESS ? 'info' : $color;
    $color = $data->status == GoodsMovement::STATUS_CLOSE ? 'success' : $color;
    return Html::tag('small', $data->nmStatus, ['class' => 'label label-' . $color]);
}]]]);
?>
                    </div>            
                </div>
                <div class="tab-pane col-lg-12" id="payments-pane">
                    Payments
                </div>
            </div>
        </div>
    </section>
</div>
<?php 
ActiveForm::end();
Exemplo n.º 18
0
$session->clearSuccesses();
foreach ($successes as $e) {
    ?>
<div class="alert alert-success"><h2><?php 
    echo $e;
    ?>
</h2></div><?php 
}
?>

<?php 
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'tableOptions' => ['class' => 'table table-striped'], 'columns' => [['attribute' => 'ticket_id', 'content' => function ($model, $index, $widget, $grid) {
    return $model->ticket->group->event->name . ': ' . $model->ticket->name;
}, 'label' => 'Ticket'], ['attribute' => 'quantity', 'content' => function ($model, $index, $widget, $grid) {
    return ($model->ticket->getAvailableQuantity() === false || $model->ticket->getAvailableQuantity() > $model->quantity ? '<a class="btn btn-xs btn-info" href="' . Url::to(['/cart/add/', 'id' => $model->ticket_id]) . '">+</a>' : '') . $model->quantity . ($model->quantity > 0 ? '<a class="btn btn-xs btn-info" href="' . Url::to(['/cart/reduce/', 'id' => $model->ticket_id]) . '">-</a>' : '');
}], ['content' => function ($model, $index, $widget, $grid) {
    return $model->ticket->ticket_price;
}, 'label' => 'Price', 'format' => 'currency'], ['content' => function ($model, $index, $widget, $grid) {
    return $model->ticket->ticket_price * $model->quantity;
}, 'label' => 'Total', 'format' => 'currency', 'contentOptions' => ['class' => 'text-right'], 'headerOptions' => ['class' => 'text-right']]]]);
?>
        <div class="alert alert-info">
            <h3>
                <?php 
if ($cart->quantity > 0) {
    ?>
                    Your total: <?php 
    echo $cart->quantity;
    ?>
 tickets totalling <?php 
    echo $formatter->asCurrency($cart->subtotal);
Exemplo n.º 19
0
        <h4>Укажите актуальные метки для книги</h4>
        <?
        $dataProvider = new yii\data\ActiveDataProvider([
            'query' => app\models\Tag::find(),
            'pagination' => false,
            'sort' => false,
        ]);

        echo yii\grid\GridView::widget([
            'dataProvider' => $dataProvider,
            'columns' => [
                'id',
                'title',
                [
                    'class' => yii\grid\CheckboxColumn::class,
                    'name' => 'tags',
                    'checkboxOptions' => function ($modelTag) use ($tagIds) {
                        $options = ['value' => $modelTag->id];
                        /** @var \app\models\Tag $modelTag */
                        return array_search($modelTag->id, $tagIds) === false ? $options : $options + ['checked' => 'checked'];
                    }
                ]
            ],
        ]);
        ?>
    </div>
</div>

<div class="form-group">
    <?php 
echo Html::submitButton($modelBook->isNewRecord ? 'Добавить' : 'Обновить', ['class' => 'btn btn-primary']);
?>
Exemplo n.º 20
0
    </div>

    <p>
        <?php 
echo yii\helpers\Html::a(\Yii::t('app', 'Create User'), ['create'], ['class' => 'btn btn-success', 'data-pjax' => '0']);
?>
    </p>

    <?php 
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $model, 'columns' => [['label' => '#', 'attribute' => 'id', 'headerOptions' => ['style' => 'width: 100px;']], ['attribute' => 'fullName', 'value' => 'fullName', 'filter' => kartik\typeahead\Typeahead::widget(['model' => $model, 'attribute' => 'fullName', 'value' => $model->getFullName(), 'dataset' => [['display' => 'value', 'remote' => ['url' => \yii\helpers\Url::to(['suggestion', 'code' => $modelCode, 'field' => 'fullName', 'value' => '%value']), 'wildcard' => '%25value'], 'limit' => $autoCompleteLimit]], 'pluginOptions' => ['highlight' => true, 'minLength' => 3]])], ['attribute' => 'phone', 'headerOptions' => ['style' => 'width: 120px;']], ['attribute' => 'email', 'format' => 'email', 'headerOptions' => ['style' => 'width: 250px;']], ['attribute' => 'logins_count', 'headerOptions' => ['style' => 'width: 40px;']], ['attribute' => 'created_at', 'format' => 'datetime', 'headerOptions' => ['style' => 'width: 150px;'], 'filter' => kartik\daterange\DateRangePicker::widget(['name' => 'User[created_at]', 'value' => $model->created_at, 'pluginOptions' => ['opens' => 'left']])], ['attribute' => 'last_login_at', 'format' => 'datetime', 'headerOptions' => ['style' => 'width: 150px;'], 'filter' => kartik\daterange\DateRangePicker::widget(['name' => 'User[last_login_at]', 'value' => $model->last_login_at, 'pluginOptions' => ['opens' => 'left']])], ['class' => \dosamigos\grid\ToggleColumn::className(), 'attribute' => 'is_active', 'onValue' => User::STATUS_ACTIVE, 'onLabel' => \Yii::t('app', 'Active'), 'offLabel' => \Yii::t('app', 'Not active'), 'contentOptions' => ['class' => 'text-center'], 'afterToggle' => 'function(r, data){}', 'onIcon' => 'glyphicon glyphicon-ok text-success', 'offIcon' => 'glyphicon glyphicon-remove text-danger', 'filter' => \app\enums\YesNo::listData(), 'headerOptions' => ['style' => 'width: 85px;']], ['class' => 'yii\\grid\\ActionColumn', 'template' => '{update} {delete}', 'buttons' => ['delete' => function ($url, $model, $key) {
    //                        if(!\Yii::$app->get('service|user')->haveDeletePermission($model->primaryKey)){
    //                            return '';
    //                        }
    $options = ['title' => \Yii::t('yii', 'Delete'), 'aria-label' => \Yii::t('yii', 'Delete'), 'data-confirm' => \Yii::t('yii', 'Are you sure you want to delete this item?'), 'data-method' => 'post', 'data-pjax' => '0'];
    return Html::a('<span class="glyphicon glyphicon-trash"></span>', $url, $options);
}, 'update' => function ($url, $model, $key) {
    //                        if(\Yii::$app->user->id == $model->primaryKey){
    //                            return '';
    //                        }
    $options = array_merge(['title' => \Yii::t('yii', 'Update'), 'aria-label' => \Yii::t('yii', 'Update'), 'data-pjax' => '0']);
    return Html::a('<span class="glyphicon glyphicon-pencil"></span>', $url, $options);
}], 'headerOptions' => ['style' => 'width: 70px;']]]]);
yii\widgets\Pjax::end();
$this->registerJs('$("document").ready(function(){
        $("#admin-user-id").on("pjax:start", function() {
            $("#admin-user-id").addClass("page-loading");
        });

        $("#admin-user-id").on("pjax:end", function() {
            $("#admin-user-id").removeClass("page-loading");
        });
Exemplo n.º 21
0
            <div class='col-sm-3'>

                <button class='btn btn-danger'>ประมวลผล</button>
            </div>
        </div>
    </form>
</div>
<a href="#" id="btn_sql">ชุดคำสั่ง</a>
<div id="sql" style="display: none"><?php 
echo $sql;
?>
</div>

    <?php 
if (isset($dataProvider)) {
    $dev = Html::a('คุณนครินทร์ เกตุวีระพงศ์', 'https://fb.com/nakharin.knott', ['target' => '_blank']);
    $y = $selyear + 543;
    $y = substr($y, 2, 2);
    $py = $y - 1;
    echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], ['attribute' => 'hoscode', 'header' => 'รหัส'], ['attribute' => 'hosname', 'header' => 'สถานบริการ'], ['attribute' => 'op_visit_pt_q1', 'header' => 'จำนวน OP<br>Q1<br>(คน)'], ['attribute' => 'op_visit_q1', 'header' => 'จำนวน OP<br>Q1<br>(ครั้ง)'], ['attribute' => 'tm_visit_pt_q1', 'header' => 'จำนวน tm <br>Q1<br>(คน)'], ['attribute' => 'tm_visit_q1', 'header' => 'จำนวน tm <br>Q1<br>(ครั้ง)'], ['attribute' => 'op_visit_pt_q2', 'header' => 'จำนวน OP <br>Q2<br>(คน)'], ['attribute' => 'op_visit_q2', 'header' => 'จำนวน OP <br>Q2<br>(ครั้ง)'], ['attribute' => 'tm_visit_pt_q2', 'header' => 'จำนวน tm <br>Q2<br>(คน)'], ['attribute' => 'tm_visit_q2', 'header' => 'จำนวน tm <br>Q2<br>(ครั้ง)'], ['attribute' => 'op_visit_pt_q3', 'header' => 'จำนวน OP <br>Q3<br>(คน)'], ['attribute' => 'op_visit_q3', 'header' => 'จำนวน OP <br>Q3<br>(ครั้ง)'], ['attribute' => 'tm_visit_pt_q3', 'header' => 'จำนวน tm <br>Q3<br>(คน)'], ['attribute' => 'tm_visit_q3', 'header' => 'จำนวน tm <br>Q3<br>(ครั้ง)'], ['attribute' => 'op_visit_pt_q4', 'header' => 'จำนวน OP <br>Q4<br>(คน)'], ['attribute' => 'op_visit_q4', 'header' => 'จำนวน OP <br>Q4<br>ครั้ง)'], ['attribute' => 'tm_visit_pt_q4', 'header' => 'จำนวน tm <br>Q4<br>(คน)'], ['attribute' => 'tm_visit_q4', 'header' => 'จำนวน tm <br>Q4<br>(ครั้ง)']]]);
}
?>

<?php 
$script = <<<JS
\$('#btn_sql').on('click', function(e) {
    
   \$('#sql').toggle();
});
JS;
$this->registerJs($script);
Exemplo n.º 22
0
<?php

use yii\helpers\Html;
$columns = array_merge([['class' => yii\grid\ActionColumn::className(), 'template' => '{delete}', 'buttons' => ['delete' => function ($url, $model, $key) {
    $options = ['title' => Yii::t('yii', 'Delete'), 'aria-label' => Yii::t('yii', 'Delete'), 'data-confirm' => Yii::t('yii', 'Are you sure you want to delete this item?'), 'data-method' => 'post', 'data-pjax' => '0'];
    return Html::a('<span class="glyphicon glyphicon-trash"></span>', ['delete-token', 'id' => $model['id']], $options);
}]]], ['label', 'tokenMask']);
$config = ['dataProvider' => $dataProvider, 'columns' => $columns];
echo yii\grid\GridView::widget($config);
Exemplo n.º 23
0
    Пользователь
    </br>
    Кошельки
    </br>
        
    <h3>Ежемесячно <small>(доходы / расходы)</small> <span class="label label-default">New</span></h3>
    <!-- Tab panes -->
    <div class="tab-content">
        <div role="tabpanel" class="tab-pane active" id="home">
            <div class="panel panel-default" style="margin: 10px auto;"> 
                <div class="panel-body"> 

                    <?php 
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['attribute' => 'catalog.name', 'label' => 'Статья', 'format' => 'html', 'value' => function ($model) {
    return yii\helpers\Html::a($model->catalog->name, yii\helpers\Url::toRoute(['catalog/view', 'id' => $model->catalog->id]));
}], ['attribute' => 'amount', 'label' => 'Размер, ₽'], ['attribute' => 'period.name', 'label' => 'Период'], ['attribute' => 'source.name', 'label' => 'Источник'], ['attribute' => 'date', 'format' => 'date', 'label' => 'Дата начала'], ['attribute' => 'enddate', 'label' => 'Окончание', 'format' => 'html', 'value' => function ($model) {
    return $model->enddate ? $model->enddate : "-";
}]], 'emptyText' => '-', 'showFooter' => true]);
?>
              

                </div> 
            </div>            
        </div>
        <div role="tabpanel" class="tab-pane" id="profile">2..</div>
        <div role="tabpanel" class="tab-pane" id="messages">.3..</div>
        <div role="tabpanel" class="tab-pane" id="settings">.4..</div>
    </div>
</div>  
          
Exemplo n.º 24
0
?>
%</span></li>
                    </ul>
                    <div class="card-grey">
                        <h4 class="heading-strip-grey"><?php 
echo $model->fullname;
?>
 is <span class="color-blue"><?php 
echo ucfirst($model->todayMood);
?>
 </span>today</h4>
                    </div>
                    <div class="card-grey">
                        <h4 class="fonts-bold color-white ">
                            <?php 
echo yii\grid\GridView::widget(['dataProvider' => $moodProvider, 'columns' => [['attribute' => 'date', 'format' => ['date', 'php: F jS, Y']], 'mood'], 'caption' => "Last Mood on"]);
?>

                        </h4>
                    </div>
                </div>
                <!-- /.box-body-->
            </div>
        </div>
    </div>

    <div class="col-lg-4">
        <div class="box box-primary top-fixed-margin grey-card-large">
            <div class="box-header with-border">
                <i class="fa fa-bar-chart-o"></i>
Exemplo n.º 25
0
echo Html::encode($this->title);
?>
</h1>


<div class="col-lg-3" style="padding-left: 0px;">
    <div class="panel panel-primary">
        <div class="panel-heading">
            Purchase Header
        </div>
        <?php 
echo DetailView::widget(['options' => ['class' => 'table table-striped detail-view', 'style' => 'padding:0px;'], 'model' => $model, 'attributes' => ['purchase_num', 'idSupplier.nm_supplier', 'purchaseDate', 'nmStatus']]);
?>
        <div class="panel-footer" style="text-align: right;">
            <?php 
if ($model->status == PurchaseHdr::STATUS_DRAFT) {
    echo Html::a('Update', ['update', 'id' => $model->id_purchase], ['class' => 'btn btn-primary']) . ' ';
    echo Html::a('Delete', ['delete', 'id' => $model->id_purchase], ['class' => 'btn btn-danger', 'data-confirm' => Yii::t('app', 'Are you sure to delete this item?'), 'data-method' => 'post']) . ' ';
    echo Html::a('Receive', ['receive', 'id' => $model->id_purchase], ['class' => 'btn btn-success', 'data-confirm' => Yii::t('app', 'Are you sure to receive this item?'), 'data-method' => 'post']);
}
?>
        </div>
    </div>    
</div>
<div class="purchase-hdr-view col-lg-9">
    <?php 
echo yii\grid\GridView::widget(['tableOptions' => ['class' => 'table table-striped'], 'layout' => '{items}', 'dataProvider' => new \yii\data\ActiveDataProvider(['query' => $model->getPurchaseDtls(), 'sort' => false, 'pagination' => false]), 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'idWarehouse.nm_whse', 'idProduct.nm_product', 'purch_qty', 'purch_price', 'selling_price', 'idUom.nm_uom']]);
?>
</div>

Exemplo n.º 26
0
        $dataProvider = new yii\data\ActiveDataProvider([
            'query' => $modelBook->getAuthors(),
        ]);

        echo yii\grid\GridView::widget([
            'dataProvider' => $dataProvider,
            'columns' => [
                'id',
                'name',
            ]
        ]);
        ?>
    </div>
    <div class="col-md-6">
        <h4>Метки для книги</h4>
        <?
        $dataProvider = new yii\data\ActiveDataProvider([
            'query' => $modelBook->getTags(),
        ]);

        echo yii\grid\GridView::widget([
            'dataProvider' => $dataProvider,
            'columns' => [
                'id',
                'title',
            ]
        ]);
        ?>
    </div>
</div>
Exemplo n.º 27
0
Arquivo: view.php Projeto: adsavin/car
/* @var $model app\models\SourceMessage */

$this->title = $model->id;
$this->params['breadcrumbs'][] = ['label' => Yii::t('app', 'Source Messages'), 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
?>
<!--<div class="source-message-view">-->
<div class="row">
    <div class="col-lg-6 col-md-6">
        <h1><?= Html::encode($this->title) ?></h1>
        <?=
        yii\grid\GridView::widget([
            'dataProvider' => $dataProvider,
            'filterModel' => $searchModel,
            'columns' => [
                ['class' => 'yii\grid\SerialColumn'],
                'category',
                'message:ntext',
                ['class' => 'yii\grid\ActionColumn'],
            ],
        ]);
        ?>
    </div>
    <div class="col-lg-6 col-md-6">
        <h1><?= Html::encode($this->title) ?></h1>

        <p>
            <?= Html::a(Yii::t('app', 'Update'), ['update', 'id' => $model->id], ['class' => 'btn btn-primary']) ?>
            <?=
            Html::a(Yii::t('app', 'Delete'), ['delete', 'id' => $model->id], [
                'class' => 'btn btn-danger',
                'data' => [
Exemplo n.º 28
0
use yii\helpers\Html;
$this->params['breadcrumbs'][] = ['label' => 'สร้างเสริมภูมิคุ้มกันโรค', 'url' => ['epi/index']];
$this->params['breadcrumbs'][] = 'ผลงานการรณรงค์ฉีดวัคซีน dTC (อายุ 20-50 ปี)';
?>

<a href="#" id="btn_sql">ชุดคำสั่ง</a>
<div id="sql" style="display: none"><?php 
echo $sql;
?>
</div>
<?php 
if (isset($dataProvider)) {
    $dev = Html::a('คุณนครินทร์ เกตุวีระพงศ์', 'https://fb.com/nakharin.knott', ['target' => '_blank']);
}
echo yii\grid\GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], ['attribute' => 'hospcode', 'header' => 'รหัส'], ['attribute' => 'hospname', 'label' => 'สถานบริการ'], ['attribute' => 'dtc_all', 'header' => 'ผลงานฉีด dTC<br>ทั้งหมด<br>(คน)'], ['attribute' => 'intarget_inhos', 'header' => 'ผลงานฉีด dTC<br>กลุ่มเป้าหมาย<br>ในสถานบริการ<br>(คน)'], ['attribute' => 'outtarget_inhos', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>ในสถานบริการ<br>(คน)'], ['attribute' => 'intarget_outhos', 'header' => 'ผลงานฉีด dTC<br>ในกลุ่มเป้าหมาย<br>นอกสถานบริการ<br>(คน)'], ['attribute' => 'outtarget_outhos', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>นอกสถานบริการ<br>(คน)'], ['attribute' => 'intarget_thai', 'header' => 'ผลงานฉีด dTC<br>ในกลุ่มเป้าหมาย<br>คนไทย<br>(คน)'], ['attribute' => 'outtarget_thai', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>คนไทย<br>(คน)'], ['attribute' => 'intarget_foreign', 'header' => 'ผลงานฉีด dTC<br>ในกลุ่มเป้าหมาย<br>คนต่างด้าว<br>(คน)'], ['attribute' => 'outtarget_foreign', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>คนต่างด้าว<br>(คน)'], ['attribute' => 'intarget_inarea', 'header' => 'ผลงานฉีด dTC<br>ในกลุ่มเป้าหมาย<br>ประชากรในเขต<br>(คน)'], ['attribute' => 'outtarget_inarea', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>ประชากรในเขต<br>(คน)'], ['attribute' => 'intarget_outarea', 'header' => 'ผลงานฉีด dTC<br>ในกลุ่มเป้าหมาย<br>ประชากรในเขต<br>(คน)'], ['attribute' => 'outtarget_outarea', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>ประชากรนอกเขต<br>(คน)'], ['attribute' => 'intarget_foreign_inarea', 'header' => 'ผลงานฉีด dTC<br>กลุ่มเป้าหมาย<br>ต่างด้าวนอกเขต<br>(คน)'], ['attribute' => 'outtarget_foreign_inarea', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>ต่างด้าวในเขต<br>(คน)'], ['attribute' => 'intarget_foreign_outarea', 'header' => 'ผลงานฉีด dTC<br>กลุ่มเป้าหมาย<br>ต่างด้าวนอกเขต<br>(คน)'], ['attribute' => 'outtarget_foreign_outarea', 'header' => 'ผลงานฉีด dTC<br>นอกกลุ่มเป้าหมาย<br>ต่างด้าวนอกเขต<br>(คน)']]]);
?>

<?php 
$script = <<<JS

\$(function(){
    \$("label[title='Show all data']").hide();
});
        
\$('#btn_sql').on('click', function(e) {
    
   \$('#sql').toggle();
});
JS;
$this->registerJs($script);