isavon / yii2-grid
The Grid extension for the Yii2 Framework
1.0
2022-07-11 12:25 UTC
Requires
- yiisoft/yii2: ~2.0.0
This package is auto-updated.
Last update: 2026-03-11 21:18:59 UTC
README
yii2-grid
Installation
The preferred way to install this extension is through composer.
To install, either run
$ php composer.phar require isavon/yii2-grid "@dev"
or add
"isavon/yii2-grid": "@dev"
to the require section of your composer.json file.
Changes
NOTE: Refer the CHANGE LOG for details on changes to various releases.
Usage
Add ActionColumn to view file.
<?= GridView::widget([ 'dataProvider' => $dataProvider, 'summary' => false, 'columns' => [ 'id', 'name', 'url', [ 'class' => 'isavon\grid\ActionColumn', 'template' => '{images} {update} {delete}', 'urls' => function($model) { return [ 'images' => Url::to(['work-image/index', 'workid' => $model->id]), ]; }, 'contentOptions' => ['class' => 'text-center'], 'header' => 'Actions', ] ] ]) ?>