Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/prawee/yii2-grid
Extends grid classes for Yii2 and Bootstrap 4
https://github.com/prawee/yii2-grid
column gridview image media php yii2 yii2-gridview
Last synced: about 2 months ago
JSON representation
Extends grid classes for Yii2 and Bootstrap 4
- Host: GitHub
- URL: https://github.com/prawee/yii2-grid
- Owner: prawee
- Created: 2014-07-18T03:49:12.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2020-08-16T13:20:39.000Z (over 4 years ago)
- Last Synced: 2024-05-02T10:11:46.311Z (8 months ago)
- Topics: column, gridview, image, media, php, yii2, yii2-gridview
- Language: PHP
- Homepage: http://www.prawee.com
- Size: 559 KB
- Stars: 2
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Extends grid classes for Yii2 and Bootstrap 4
## Contains
- ActionAuthColumn
- ActionChildColumn
- ActionColumn
- ActionRuleColumn
- ImageColumn
- MediaColumn## Installation
on your terminal run this command
```php
php composer.phar require prawee/yii2-grid "dev-master"
```or add to composer.json on require path.
```php
"prawee/yii2-grid": "dev-master"
```## Usage
### ActionColumn
on your grid
```php
....
[
'class'=>'prawee\grid\ActionColumn',
],
.....
```#### ImageColumn
on your grid
```php
....
[
'class'=>'prawee\grid\ImageColumn',
'attribute'=>'image',
'options'=>[
'width'=>'40px',
],
],
....
```#### ActionChildColumn
on your grid
```php
...
[
'class'=>'prawee\grid\ActionChildColumn',
],
...
```or it have child that's support multi param
```php
...
[
'class'=>'prawee\grid\ActionChildColumn',
'params'=>[
'ref'=>Yii::$app->getRequest()->get('id'),
'station'=>2,
],
],
...
```#### MediaColumn
on your grid
```php
....
[
'class'=>'prawee\grid\MediaColumn',
'attribute'=>'name',
'format'=>'image', #image,video
'options'=>[
'width'=>'40px',
],
],
....
```