Assalamualaikum Wr. Wb
Halo semua ini tadi ane habis searching di forum yii terus nemu topik tentang TbExtendedGridView
mungkin yang baca ini juga perlu tentang tutorial ini sok silahkan di sedot.
okay langsung aja cekitdot
pada Bootstrap.widgets.TbExtendedGridView yang ada pada bootstrap.
atau lebih jelas lihat di http://yii-booster.clevertech.biz/extended-grid.html
atau kalau males buka lihat kode ini aja deh
code pada bootstrap:
okay setelah anda melihat code di atas sekarang code di bawah ini adalah code hasil modifikasi yang telah terhubung dengan model pada NamaAplikasiAnda/protected/views/viewanda/admin.php
Halo semua ini tadi ane habis searching di forum yii terus nemu topik tentang TbExtendedGridView
mungkin yang baca ini juga perlu tentang tutorial ini sok silahkan di sedot.
okay langsung aja cekitdot
pada Bootstrap.widgets.TbExtendedGridView yang ada pada bootstrap.
atau lebih jelas lihat di http://yii-booster.clevertech.biz/extended-grid.html
atau kalau males buka lihat kode ini aja deh
code pada bootstrap:
- $this->widget('bootstrap.widgets.TbExtendedGridView', array(
- 'type' => 'striped bordered',
- 'dataProvider' => $gridDataProvider,
- 'template' => "{items}",
- 'bulkActions' => array(
- 'actionButtons' => array(
- array(
- 'buttonType' => 'button',
- 'type' => 'primary',
- 'size' => 'small',
- 'label' => 'Testing Primary Bulk Actions',
- 'click' => 'js:function(values){console.log(values);}'
- )
- ),
- // if grid doesn't have a checkbox column type, it will attach
- // one and this configuration will be part of it
- 'checkBoxColumnConfig' => array(
- 'name' => 'id'
- ),
- ),
- 'columns' => $gridColumns,
- ));
okay setelah anda melihat code di atas sekarang code di bawah ini adalah code hasil modifikasi yang telah terhubung dengan model pada NamaAplikasiAnda/protected/views/viewanda/admin.php
->widget('bootstrap.widgets.TbExtendedGridView', array(
'type' => 'striped bordered',
'dataProvider'=>$model->search(),
'filter'=>$model,
'template' => "{items}",
'bulkActions' => array(
'actionButtons' => array(
array(
'buttonType' => 'button',
'type' => 'primary',
'size' => 'small',
'label' => 'Testing Primary Bulk Actions',
'click' => 'js:function(values){console.log(values);}'
)
),
// if grid doesn't have a checkbox column type, it will attach
// one and this configuration will be part of it
'checkBoxColumnConfig' => array(
'name' => 'no'
),
),
'columns' => array(
'no',
'nama',
'path',
'ukuran',
'lvl',
array(
'class'=>'CButtonColumn',
),
),
));
?>
Okay kalau begitu Semoga berhasil ya
:)
~Happy Coding~
0 Komentar