From https://sourceforge.net/p/allura/tickets/7716/
Changing "Page Size" on /auth/preferences doesn't do anything.
There are a lot of places where page size set manually to some value. E.g. ticket controller sets it to 10, wiki's and discussion to 25, probably there's more places like that.
There are also two helpers used throughout code for pagination
g.handle_paging
andh.paging_sanitizer
. While former is using page size preference, the latter is not.Other than that
g.handle_paging
uses some strange (to me) logic. It sets your page size preference to the particular value, if limit is provided (e.g. by manually appending?limit=N
to url, or when hard limit is provided inside the controller). Thus page size is reset in very obscure (to the user) way.Most obvious and easy to use way would be to always use page size from user preferences for all pages (if it is not overridden by controller for some reason) and avoid resetting this setting as described above.
?limit=N
url paramh.paging_sanitizer
& g.handle_paging
into one to avoid future confusions
Closed #677.
ib/7794
I didn't merge
paging_sanitizer
&handle_paging
, since they are used for slightly different purposes, and sanitizer always requires total count, which is not available in a lot of places where pagination is used.I've changed logic of
handle_paging
to more straightforward and have removed hard pagination limit in controllers, where it made sense.Also, I've "greped" through extensions and forge-classic and found only one hard coded limit in mailman app. I didn't change that, though, since we had issues with performance there, so hard limit makes sense to me.
Looks pretty good, but found 2 minor issues:
handle_paging
hasdefault=50
, so practically the default default is 50 in most places.Closed #686.
+ 9aba981...d62cd94 t686_page_size_amends -> ib/7794 (forced update)