[patch] The archive_year date-based generic view should not override a model's default ordering
|Reported by:||Owned by:||Jacob|
|Cc:||gary.wilson@…||Triage Stage:||Design decision needed|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
archive_day date-based generic views all respect a model's default ordering — that is, none of those generic views append
order_by() when they filter a
archive_year view, however, will always return a chronological list of objects; this cannot be overridden.
The offending code is line 79 (in the current Subversion trunk).
I might be wrong, but I think
archive_year should adhere to a model's default ordering, as the related date-based views do. But since this would change the expected behaviour of a lot of existing sites, I guess an optional parameter allowing a programmer to specify the ordering would be nice. I'll attach a patch.
Change History (10)
comment:1 Changed 10 years ago by
|Summary:||The archive_year date-based generic view should not override a model's default ordering → [patch] The archive_year date-based generic view should not override a model's default ordering|