kartik-v / yii2-export

A library to export server/db data in various formats (e.g. excel, html, pdf, csv etc.)
http://demos.krajee.com/export
Other
165 stars 126 forks source link

fix the loss of the first page if batchSize #302

Closed onmotion closed 5 years ago

onmotion commented 5 years ago

Scope

This pull request includes a

Changes

The following changes were made (this change is also documented in the change log):

Related Issues

If this is related to an existing ticket, include a link to it as well.

If use the batchSize parameter it redefine pagination pagesize. But in first (while it is not set yet) in https://github.com/kartik-v/yii2-export/blob/19483fdc69d427966ffb80c8ea5283c1be2036f9/src/ExportMenu.php#L1782 the default pagesize models are requested and stored up into _models (var cache), so without the $forcePrepare param we loosing first page

image

Loss step:

image

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.