Reputation: 1499
I want to show rows in descending order in Manage page, so what should I do for displaying more than 10 rows in *.widgets.TbGridView? Any Help?
Upvotes: 1
Views: 282
Reputation: 1499
Displaying 30 rows in pagination
return new CActiveDataProvider($this, array(
'pagination' => array(
'pageSize' => 30,
),
'criteria' => $criteria,
));
Display Initial rows in descending order
$criteria->order = "t.id DESC";
Upvotes: 0
Reputation: 8033
You pass CActiveDataProvider
to CGridView
or TbGridView
in the manage action. All you need to do is passing the page size to dataprovider:
return new CActiveDataProvider($this, array(
'pagination' => array(
'pageSize' => 20,
),
'criteria' => $criteria,
));
Upvotes: 1