nterms / yii2-pagesize-widget

Widget for enabling dynamic page size selection on yii2 GridView
MIT License
38 stars 18 forks source link

Pagination config #2

Closed arogachev closed 9 years ago

arogachev commented 10 years ago

In sizes values more than 50 don't work because Pagination have limitation to show only 1 to 50 records by default.

Also sometimes we need to change default page size. As I understand defaultPageSize only affects the default selected value in drop-down list. Pagination default page size is 20 records.

Currently it's not possible with this extension and before GridView widget we need to write something like that:

$dataProvider->setPagination([
    'defaultPageSize' => 25,
    'pageSizeLimit' => [1, 100],
]);

It would be better if this extension have this functionality built-in.

nterms commented 9 years ago

This small widget is created to make use of filterSelector property of the GridView. And no control over the the GridView supperted by it. I think better set the limit on GridView itself.