예제 #1
0
?>
                <?php 
if (Mimin::filterRoute($this->context->id . '/tabuang')) {
    ?>
                    <li>
                        <a href="<?php 
    echo Url::to(['simpel-keg/bendahara']);
    ?>
" >
                            Bendahara </a>
                    </li>
                <?php 
}
?>
                <?php 
if (Mimin::filterRoute($this->context->id . '/tabarsip')) {
    ?>
                    <li class="active">
                        <a href="<?php 
    echo Url::to(['simpel-keg/varsip']);
    ?>
" >
                            Arsip </a>
                    </li>
                <?php 
}
?>
            </ul>
        </div>
        <?php 
Pjax::begin(['id' => 'dinasSearch']);
예제 #2
0
파일: index.php 프로젝트: hscstudio/psaham
/* @var $this yii\web\View */
/* @var $searchModel app\models\ParamfundSearch */
/* @var $dataProvider yii\data\ActiveDataProvider */
$this->title = 'Parameter Fundamental';
$this->params['breadcrumbs'][] = $this->title;
?>
<div class="paramfund-index">
    <?php 
// echo $this->render('_search', ['model' => $searchModel]);
?>
    <?php 
Pjax::begin(['id' => 'paramfund-index-pjax']);
?>

    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'responsive' => true, 'hover' => true, 'resizableColumns' => false, 'showPageSummary' => true, 'showFooter' => true, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-th"></i> <span class="hidden-xs"></span> ' . Html::encode($this->title) . '</h3>', 'before' => (Mimin::filterRoute($this->context->id . '/create') ? Html::a('Create', ['create'], ['class' => 'btn btn-success', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Create Data Parameter", 'data-size' => "modal-lg"]) : '') . ' '], 'toolbar' => [['content' => Html::a('<i class="glyphicon glyphicon-repeat"></i>', ['index', 'date' => $dates[1]], ['data-pjax' => 0, 'class' => 'btn btn-default', 'title' => 'Reset Grid'])], ButtonExport::widget()], 'export' => ['fontAwesome' => true], 'columns' => [['class' => 'kartik\\grid\\SerialColumn'], ['attribute' => 'EMITEN_KODE', 'label' => 'Emiten', 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'TAHUN', 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'TRIWULAN', 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'CE', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'CA', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'TA', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'TE', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'CL', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'TL', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['class' => 'kartik\\grid\\ActionColumn', 'hAlign' => 'center', 'vAlign' => 'middle', 'options' => ['width' => '100px'], 'template' => Mimin::filterTemplateActionColumn(['view', 'update', 'delete'], $this->context->route), 'buttons' => ['view' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-eye-open"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "View Data Parameter"]);
}, 'update' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-pencil"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Update Data Parameter", 'data-size' => "modal-lg"]);
}, 'delete' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-trash"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-confirm' => "Apakah anda mau menghapus data ini?", 'data-method' => 'post']);
}]]]]);
?>
    <?php 
Pjax::end();
?>
</div>
예제 #3
0
</title>
    <?php 
$this->head();
?>
</head>
<body>
<?php 
$this->beginBody();
?>

<div class="wrap">
    <?php 
NavBar::begin(['brandLabel' => 'My Company', 'brandUrl' => Yii::$app->homeUrl, 'options' => ['class' => 'navbar-inverse navbar-fixed-top']]);
$menuItems = [['label' => 'Home', 'url' => ['/site/index']]];
$items = [['label' => 'Monthly', 'url' => ['/mimin/user/']], ['label' => 'Yearly', 'url' => ['/mimin/routeuu/']]];
$items = Mimin::filterRouteMenu($items);
if (count($items) > 0) {
    $menuItems[] = ['label' => 'Reporting', 'items' => $items];
}
echo Nav::widget(['options' => ['class' => 'navbar-nav navbar-right'], 'items' => $items]);
NavBar::end();
?>

    <div class="container">
        <?php 
echo Breadcrumbs::widget(['links' => isset($this->params['breadcrumbs']) ? $this->params['breadcrumbs'] : []]);
?>
        <?php 
echo Alert::widget();
?>
        <?php 
예제 #4
0
파일: index.php 프로젝트: hscstudio/psaham
$parent = substr($permission, 0, $pos);
echo $parent;
*/
?>
<div class="securitas-index">
    <!-- <div class="ui divider"></div> -->
    <?php 
// echo $this->render('_search', ['model' => $searchModel]);
?>

    <?php 
Pjax::begin(['id' => 'securitas-index-pjax']);
?>

    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'responsive' => true, 'responsiveWrap' => true, 'hover' => true, 'resizableColumns' => false, 'showFooter' => true, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-th"></i> <span class="hidden-xs"></span> ' . Html::encode($this->title) . '</h3>', 'before' => '<div class="row">' . '<div class="col-xs-2 col-lg-1">' . (Mimin::filterRoute($this->context->id . '/create') ? Html::a('Create', ['create'], ['class' => 'btn btn-success', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Create Data Securitas"]) : '') . ' ' . '</div>' . '<div class="col-xs-5 col-sm-4 col-md-3 col-lg-2">' . '</div>' . '</div>'], 'toolbar' => [['content' => Html::a('<i class="glyphicon glyphicon-repeat"></i>', ['index'], ['data-pjax' => 0, 'class' => 'btn btn-default', 'title' => 'Reset Grid'])], ButtonExport::widget()], 'export' => ['fontAwesome' => true], 'columns' => [['class' => 'kartik\\grid\\SerialColumn'], ['attribute' => 'KODE', 'label' => 'Kode', 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'NAMA', 'label' => 'Nama', 'options' => [], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'left', 'vAlign' => 'middle'], ['attribute' => 'ALAMAT', 'options' => [], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'left', 'vAlign' => 'middle'], ['attribute' => 'TELP', 'options' => [], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'left', 'vAlign' => 'middle'], ['attribute' => 'HP', 'options' => [], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'left', 'vAlign' => 'middle'], ['attribute' => 'CP', 'label' => 'Kontak', 'options' => ['width' => '140px'], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'left', 'vAlign' => 'middle'], ['class' => 'kartik\\grid\\ActionColumn', 'hAlign' => 'center', 'vAlign' => 'middle', 'options' => ['width' => '100px'], 'template' => Mimin::filterTemplateActionColumn(['view', 'update', 'delete'], $this->context->route), 'buttons' => ['view' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-eye-open"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "View Data Securitas"]);
}, 'update' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-pencil"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Update Data Securitas"]);
}, 'delete' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-trash"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-confirm' => "Apakah anda mau menghapus data ini?", 'data-method' => 'post']);
}]]]]);
?>
    <?php 
Pjax::end();
?>

</div>
예제 #5
0
echo Html::a(Yii::t('app', '<i class="fa fa-list"></i>'), ['index'], ['class' => 'btn btn-alt btn-sm btn-default', 'data-toggle' => 'tooltip', 'title' => '', 'data-original-title' => 'Tambah User']);
?>
</div>
   <h6><?php 
echo Html::encode($this->title);
?>
</h6>

       
    <div class="block-options pull-right">
     <?php 
if (Mimin::filterRoute($this->context->id . '/create')) {
    echo Html::a(Yii::t('app', '<i class="fa fa-plus"></i>'), ['create'], ['class' => 'btn btn-alt btn-sm btn-default', 'data-toggle' => 'tooltip', 'title' => '', 'data-original-title' => 'Tambah User']);
    ?>


<?php 
}
?>
</div>
</div>
<div class="wp-posts-index">

    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'content:ntext', 'status', 'create_time:datetime', 'author', ['class' => 'yii\\grid\\ActionColumn', 'template' => Mimin::filterTemplateActionColumn(['update', 'delete', 'view'], $this->context->route)]]]);
?>

</div>
</div>
</div>
예제 #6
0
파일: index.php 프로젝트: hscstudio/psaham
?>
<div class="asset-index">
    <?php 
// echo $this->render('_search', ['model' => $searchModel]);
?>
    <?php 
Pjax::begin(['id' => 'pjax-gridview']);
?>
    <?php 
$this->registerJs('
      var startDate = "' . $dates[0] . '";
      var endDate = "' . $dates[2] . '";
    ');
?>
    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'responsive' => true, 'responsiveWrap' => true, 'hover' => true, 'resizableColumns' => false, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-th"></i> <span class="hidden-xs"></span> ' . Html::encode($this->title) . '</h3>', 'before' => '<div class="row">' . '<div class="col-xs-2 col-lg-1">' . (Mimin::filterRoute($this->context->id . '/create') ? Html::a('Create', ['create'], ['class' => 'btn btn-success', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-title' => "Create Data Asset"]) : '') . ' ' . '</div>' . '</div><br>' . '<table class="table table-condensed" style="width:50%">' . '<tr>' . '<td> start' . DatePicker::widget(['name' => 'start', 'value' => $dates[1], 'removeButton' => false, 'options' => ['placeholder' => 'Start ...'], 'readonly' => true, 'pluginOptions' => ['todayHighlight' => true, 'todayBtn' => true, 'format' => 'dd-M-yyyy', 'autoclose' => true, 'buttonClose' => false], 'pluginEvents' => ["changeDate" => "function(e) {\n                          startDate = e.format(0,'yyyy-m-d');\n                          \$.pjax.reload({\n            \t\t\t\t\t\t\t\turl: '" . Url::to(['index']) . "?start='+startDate+'&end='+endDate,\n            \t\t\t\t\t\t\t\tcontainer: '#pjax-gridview',\n            \t\t\t\t\t\t\t\ttimeout: 1,\n            \t\t\t\t\t\t\t});\n                      }"]]) . '</td>' . '<td> <br>s.d </td>' . '<td> end' . DatePicker::widget(['name' => 'end', 'value' => $dates[3], 'removeButton' => false, 'options' => ['placeholder' => 'End ...'], 'readonly' => true, 'pluginOptions' => ['todayHighlight' => true, 'todayBtn' => true, 'format' => 'dd-M-yyyy', 'autoclose' => true, 'buttonClose' => false], 'pluginEvents' => ["changeDate" => "function(e) {\n                          endDate = e.format(0,'yyyy-m-d');\n                          \$.pjax.reload({\n            \t\t\t\t\t\t\t\turl: '" . Url::to(['index']) . "?start='+startDate+'&end='+endDate,\n            \t\t\t\t\t\t\t\tcontainer: '#pjax-gridview',\n            \t\t\t\t\t\t\t\ttimeout: 1,\n            \t\t\t\t\t\t\t});\n                      }"]]) . '</td>' . '</tr>' . '</table>'], 'toolbar' => [['content' => Html::a('<i class="glyphicon glyphicon-repeat"></i>', ['index'], ['data-pjax' => 0, 'class' => 'btn btn-default', 'title' => 'Reset Grid'])], ButtonExport::widget()], 'export' => ['fontAwesome' => true], 'columns' => [['class' => 'kartik\\grid\\SerialColumn'], ['attribute' => 'TGL', 'format' => ['date', 'php:d-M-Y'], 'filter' => false, 'hAlign' => 'center', 'vAlign' => 'middle', 'options' => ['width' => '200px']], ['attribute' => 'KAS_BANK', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'TRAN_JALAN', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'INV_LAIN', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'STOK_SAHAM', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['class' => 'kartik\\grid\\ActionColumn', 'hAlign' => 'center', 'vAlign' => 'middle', 'options' => ['width' => '100px'], 'template' => Mimin::filterTemplateActionColumn(['view', 'update', 'delete'], $this->context->route), 'buttons' => ['view' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-eye-open"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "View Data Asset"]);
}, 'update' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-pencil"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0']);
}, 'delete' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-trash"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-confirm' => "Apakah anda mau menghapus data ini?", 'data-method' => 'post']);
}]]]]);
?>
    <?php 
Pjax::end();
?>
</div>
예제 #7
0
파일: index.php 프로젝트: hscstudio/psiaga
$this->title = 'Notes';
$this->params['breadcrumbs'][] = $this->title;
?>
<div class="note-index">

    <?php 
// echo $this->render('_search', ['model' => $searchModel]);
?>

    <?php 
Pjax::begin(['id' => 'note-index-pjax']);
?>
    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'responsive' => true, 'hover' => true, 'resizableColumns' => false, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-file"></i> <span class="hidden-xs"></span> ' . Html::encode($this->title) . '</h3>', 'before' => '<div class="row">' . '<div class="col-xs-2 col-lg-1">' . (Mimin::filterRoute($this->context->id . '/create') ? Html::a('Create', ['create'], ['class' => 'btn btn-success', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Create Data Note"]) : '') . ' ' . '</div>' . '<div class="col-xs-5 col-sm-4 col-md-3 col-lg-2">' . '</div>' . '</div>'], 'toolbar' => [['content' => Html::a('<i class="glyphicon glyphicon-repeat"></i>', ['index'], ['data-pjax' => 0, 'class' => 'btn btn-default', 'title' => 'Reset Grid'])]], 'export' => ['fontAwesome' => true], 'columns' => [['class' => 'kartik\\grid\\SerialColumn'], 'title', ['attribute' => 'content', 'format' => 'ntext', 'value' => function ($data) {
    return substr($data->content, 0, 150) . '...';
}], ['attribute' => 'updated_at', 'label' => 'Last Update', 'filter' => false, 'format' => ['date', 'php:d M Y H:i:s'], 'options' => ['width' => '125px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['class' => 'kartik\\grid\\ActionColumn', 'headerOptions' => ['style' => 'text-align:center'], 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle', 'template' => Mimin::filterTemplateActionColumn(['update', 'delete', 'download'], $this->context->route), 'buttons' => ['view' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-eye-open"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "View Data Note"]);
}, 'update' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-pencil"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Update Data Note"]);
}, 'delete' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-trash"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-confirm' => "Apakah anda mau menghapus data ini?", 'data-method' => 'post']);
}, 'download' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-download"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-title' => "Download file sebagai text"]);
}]]]]);
?>
    <?php 
Pjax::end();
예제 #8
0
                <?php 
if (Mimin::filterRoute($this->context->id . '/create')) {
    ?>
                <?php 
    echo Html::a(Yii::t('app', '<i class="fa fa-plus"></i>'), ['create'], ['class' => 'btn btn-alt btn-sm btn-default', 'data-toggle' => 'tooltip', 'title' => '', 'data-original-title' => 'Tambah User']);
    ?>
                <?php 
}
?>
            </div>
        </div>
        <div class="wp-posts-index">
            <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'title', 'content:ntext', ['class' => 'yii\\grid\\DataColumn', 'attribute' => 'category_id', 'value' => function ($data) {
    return $data->category->name;
}], ['attribute' => 'status', 'value' => function ($data) {
    return $data->status == 1 ? "Publish" : "Draft";
}], ['class' => 'yii\\grid\\ActionColumn', 'contentOptions' => ['style' => 'width:170px; z-index:20;'], 'header' => 'Actions', 'template' => Mimin::filterTemplateActionColumn(['view', 'update', 'delete'], $this->context->route), 'buttons' => ['view' => function ($url, $model) {
    return Html::a(' <button type="button" class="btn btn-danger data-placement="top">
            lihat
            </button>', Yii::$app->urlManager->createUrl(['post/view', 'tahun' => $model->tahun, 'judul' => $model->title]), ['title' => Yii::t('yii', 'Proses'), 'data-confirm' => Yii::t('yii', 'Apakah Anda Yakin Ingin Melakukan Proses?')]);
}, 'update' => function ($url, $model) {
    return Html::a(' <button type="button" class="btn btn-danger data-placement="top">
            Ubah
            </button>', Yii::$app->urlManager->createUrl(['post/update', 'tahun' => $model->tahun, 'judul' => $model->title]), ['title' => Yii::t('yii', 'Proses'), 'data-confirm' => Yii::t('yii', 'Apakah Anda Yakin Ingin Melakukan Proses?')]);
}]]]]);
?>
        </div>
    </div>

</div>
예제 #9
0
파일: index.php 프로젝트: hscstudio/psaham
// echo $this->render('_search', ['model' => $searchModel]);
?>

    <?php 
Pjax::begin(['id' => 'pembelian-index-pjax']);
?>
    <?php 
$total_lot = 1;
?>
    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'responsive' => true, 'hover' => true, 'resizableColumns' => false, 'showPageSummary' => true, 'showFooter' => true, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-shopping-cart"></i> ' . Html::encode($this->title) . '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;' . '(<span class="hidden-xs">tanggal</span> transaksi terakhir ' . ($latestDate[1] == 1 ? 'belum ada' : $latestDate[1]) . ')</h3>', 'before' => '<div class="row">' . '<div class="col-xs-2 col-lg-1">' . (Mimin::filterRoute($this->context->id . '/create') ? Html::a('Create', ['create', 'date' => $dates[1]], ['class' => 'btn btn-success', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Create Data Pembelian", 'data-size' => "modal-lg"]) : '') . ' ' . '</div>' . '<div class="col-xs-2 col-md-1">' . Html::dropDownList('per-page', $perpage, ['5' => '5', '10' => '10', '20' => '20', '50' => '50', '100' => '100', 'all' => 'all'], ['id' => 'per-page', 'class' => 'form-control']) . '</div>' . '<div class="col-xs-5 col-sm-4 col-md-3 col-lg-2">' . DatePicker::widget(['name' => 'grid_date', 'value' => $dates[1], 'removeButton' => false, 'options' => ['placeholder' => 'Tgl Grid ...'], 'readonly' => true, 'pluginOptions' => ['todayHighlight' => true, 'todayBtn' => true, 'format' => 'dd-M-yyyy', 'autoclose' => true, 'buttonClose' => false], 'pluginEvents' => ["changeDate" => "function(e) {\n                          \$.pjax.reload({\n            \t\t\t\t\t\t\t\turl: '" . Url::to(['index']) . "?per-page='+" . $perpage . "+'&date='+e.format(0,'yyyy-m-d'),\n            \t\t\t\t\t\t\t\tcontainer: '#pembelian-index-pjax',\n            \t\t\t\t\t\t\t\ttimeout: 1,\n            \t\t\t\t\t\t\t});\n                      }"]]) . '</div>' . '</div>'], 'toolbar' => [['content' => Html::a('<i class="glyphicon glyphicon-repeat"></i>', ['index'], ['data-pjax' => 0, 'class' => 'btn btn-default', 'title' => 'Reset Grid'])], ButtonExport::widget()], 'export' => ['fontAwesome' => true], 'columns' => [['class' => 'kartik\\grid\\SerialColumn'], ['attribute' => 'TGL', 'header' => 'Tanggal', 'filter' => false, 'format' => ['date', 'php:d M Y'], 'options' => ['width' => '125px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'NOMOR', 'label' => 'Nomor', 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'EMITEN_KODE', 'label' => 'Emiten', 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'SECURITAS_KODE', 'label' => 'Securitas', 'options' => ['width' => '100px'], 'hAlign' => 'center', 'vAlign' => 'middle'], ['attribute' => 'JMLLOT', 'label' => 'Jml Lot', 'format' => ['decimal', 2], 'options' => ['width' => '100px'], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle', 'pageSummary' => true, 'pageSummaryFunc' => GridView::F_SUM], ['attribute' => 'JMLSAHAM', 'label' => 'Jml Saham', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle', 'pageSummary' => true, 'pageSummaryFunc' => GridView::F_SUM], ['attribute' => 'HARGA', 'label' => 'Harga', 'format' => ['decimal', 2], 'options' => ['width' => '100px'], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle', 'pageSummary' => true, 'pageSummaryFunc' => GridView::F_SUM], ['attribute' => 'KOM_BELI', 'label' => 'Komisi', 'format' => ['decimal', 2], 'options' => ['width' => '100px'], 'headerOptions' => ['style' => 'text-align:center'], 'value' => function ($data) {
    // 2.	Perhitungan Total Komisi = kom_beli * harga * share / 100
    $bruto = $data->JMLSAHAM * $data->HARGA;
    $komisi_total = $data->KOM_BELI * $bruto / 100;
    return $komisi_total;
}, 'hAlign' => 'right', 'vAlign' => 'middle', 'pageSummary' => true, 'pageSummaryFunc' => GridView::F_SUM], ['attribute' => 'TOTAL_BELI', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle', 'pageSummary' => true, 'pageSummaryFunc' => GridView::F_SUM], ['class' => 'kartik\\grid\\ActionColumn', 'hAlign' => 'center', 'vAlign' => 'middle', 'options' => ['width' => '100px'], 'template' => Mimin::filterTemplateActionColumn(['update', 'delete'], $this->context->route), 'buttons' => ['update' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-pencil"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Update Data Pembelian", 'data-size' => "modal-lg"]);
}, 'delete' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-trash"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-confirm' => "Apakah anda mau menghapus data ini?", 'data-method' => 'post']);
}]]]]);
?>
    <?php 
$this->registerJs('
      $("#per-page").on("change", function () {
        $.pjax.reload("#pembelian-index-pjax", {
          url: "' . Url::to(['index', 'date' => $dates[0]]) . '&per-page="+$(this).val(),
          container: "#pembelian-index-pjax",
          timeout: 3000,
          push: true,
예제 #10
0
파일: index.php 프로젝트: hscstudio/psaham
$this->params['breadcrumbs'][] = $this->title;
?>
<div class="indikator-index">
    <!-- <div class="ui divider"></div> -->
    <?php 
// echo $this->render('_search', ['model' => $searchModel]);
?>

    <?php 
//Pjax::begin([
//'id'=>'pjax-gridview',
//]);
?>

    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'responsive' => true, 'responsiveWrap' => true, 'hover' => true, 'resizableColumns' => false, 'showFooter' => true, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-th"></i> <span class="hidden-xs"></span> ' . Html::encode($this->title) . '</h3>', 'before' => '<div class="row">' . '<div class="col-xs-2 col-lg-1">' . (Mimin::filterRoute($this->context->id . '/create') ? Html::a('Create', ['create', 'tgl' => date('Y-m-d', strtotime($searchModel->TGL))], ['class' => 'btn btn-success', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Create Data Indikator"]) : '') . ' ' . '</div>' . '<div class="col-xs-5 col-sm-4 col-md-3 col-lg-2">' . '</div>' . '</div>'], 'toolbar' => [], 'export' => ['fontAwesome' => true], 'columns' => [['class' => 'kartik\\grid\\SerialColumn'], ['attribute' => 'NAMA', 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'left', 'vAlign' => 'middle'], ['attribute' => 'NAVAT', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'NAV', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['attribute' => 'TUMBUH', 'format' => ['decimal', 2], 'headerOptions' => ['style' => 'text-align:center'], 'hAlign' => 'right', 'vAlign' => 'middle'], ['class' => 'kartik\\grid\\ActionColumn', 'hAlign' => 'center', 'vAlign' => 'middle', 'options' => ['width' => '100px'], 'template' => Mimin::filterTemplateActionColumn(['view', 'update', 'delete'], $this->context->route), 'buttons' => ['view' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-eye-open"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "View Data Indikator"]);
}, 'update' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-pencil"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs', 'data-pjax' => '0', 'data-toggle' => "modal", 'data-target' => "#myModal", 'data-title' => "Update Data Indikator"]);
}, 'delete' => function ($url, $model) {
    $icon = '<span class="glyphicon glyphicon-trash"></span>';
    return Html::a($icon, $url, ['class' => 'btn btn-default btn-xs pjax-delete', 'data-pjax-container' => 'pjax-indikator', 'data-confirm-message' => 'Yakin akan menghapus data ini?']);
}]]]]);
?>

    <?php 
if (Yii::$app->request->isAjax) {
    AlertBlock::widget(Yii::$app->params['alertBlockConfig']);
    GrowlLoad::reload($this);