Tuesday 10 February 2015

Yii2 Modify GridView Filters


In Yii2  the filter input fields are automatically generated by the widget component, but we can modify to our needs by using the "filterPosition" property in Gridview widget.


To remove entire filters on Gridview,

'filterPosition'=>' ',

To show the fiters  on  top of each column's header cell,

  'filterPosition'=>'header',

To show the fiters  right below of each column's header cell,

 'filterPosition'=>'body',


To show the fiters  below each column's footer cell,

 'filterPosition'=>'footer',






No comments:

Post a Comment