How to remove summary and sorter for a particular grid view in Yii2. In Yii1.1 we can do that by setting the template property. In yii2 how to achieve this?
相关问题
- Views base64 encoded blob in HTML with PHP
- Laravel Option Select - Default Issue
- PHP Recursively File Folder Scan Sorted by Modific
- Can php detect if javascript is on or not?
- Using similar_text and strpos together
Set the paremeter
summaryText
to empty string:Got it.By setting the layout property,we can achieve it.
To change only
summary
option, you can use:Then, if you want to empty
summary
set with empty string value like:and to change layouts you can use:
Then, if you want to empty
layouts
set layout with empty string value like:Ref link
Ref link
So, for sample, i think bellow sample code can be help know how to change and custome
GridView
table in Yii 2:if you want only grid items use
'layout'=>"{items}"
if you want only summary use
'layout'=>"{summary}"
if you want only sorter use
'layout'=>"{pager}"