You are viewing revision #3 of this wiki article.
This is the latest version of this article.
You may want to see the changes made in this revision.
some times we want to show the serialNo on cgridview .
$this->widget('zii.widgets.grid.CGridView', array(
'dataProvider'=>$model->search(),
'filter'=>$model,
'columns'=>array(
array(
'header'=>'Sr #',
'value'=>'$this->grid->dataProvider->pagination->currentPage * $this->grid->dataProvider->pagination->pageSize + ($row+1)',
),
............
));
User Contributed Notes 5
Thx
Thx for wiki,This is good ;)
Simple but useful
Thanks.
Great !!
Its really a great!!
@Nisanth thulasi
Good
Thanks!
It works beautifully =D
Leave a comment
If you have any questions, please ask in the forum instead.
Join the conversation to share a note.