-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not Support auto Search? #25
Comments
I don't consider it a bug that you have to provide routing information such as controller action and route params. you have to do that also for anchor tag why should this be any different? I don't think it should auto parse anything from the url of the current request or make any assumptions about ambient query string params. |
anchor tag is for a specific url: one link for one page, difference querystring might have different content. But this library Pagination is for a list to move next or forward, so it's very important to make sure it's the same list between (Next Page or Previous Page) and current Page. Another reason is that to preserve the search queryString in action,viewBag,and Pagination for every action is very hard (multi search box). |
yes you should preserve the needed params in your viewmodel (from the current request) and use it to pass the route params to the pager, the pager should not try to guess what you want. If you want an example, I'm using it for search in a number of places in cloudscribe Core project, for example in role administration to search for roles and role members and role non members. In all cases I'm providing the needed route parameters to the pagertaghelper from my viewmodel Example view, viewmodel, controller it is your job to pass what you need for routing it is not the job of the pagertaghelper to try to guess it. if you want that you can always fork the project and implement it as you think it should be |
Current I must define
asp-action
,asp-controller
,asp-route-*
for a search. Is this a Bug?it should support auto parse QueryString to those links
The text was updated successfully, but these errors were encountered: