joeharrison714 / MVCGrid.Net

http://mvcgrid.net
MIT License
74 stars 55 forks source link

Page parameters return old values in WithRetrieveDataMethod #29

Open YogeshLele opened 8 years ago

YogeshLele commented 8 years ago

I have a partial view that is rendered 'n' times and every time controller sends back new page parameters and I can verify those getting sent correctly from server side.

However, when there is second client-request is sent (say by MVCGrid.init() or MVCGrid.ReloadGrid('example') or by sorting), the pageParameters received in the WithRetrieveDataMethod are not updated, I see the parameters from first request only.

When debugged on client side, the pp_ value is not updated in the request.

joeharrison714 commented 8 years ago

Hi YogeshLele, PageParameters are meant to pass data from the View to the grid one time on load only. I think what you may be looking for are AdditionalQueryOptions. Please see this example for more info and let me know if you have questions: http://mvcgrid.net/demo/globalsearch

Thanks, Joe

shefaliA commented 8 years ago

Joe,

I am facing similar issue. I want to enable PageSize selection using dropdown.The pageSize is being passed in Querystring.But options.GetLimitRowcount().Value is always setting to default value.Do I also have to use AdditionalQueryOptions?