Undocumented
Class |
|
Base class for archives of date-based items. Requires a response mixin. |
Class |
|
Detail view of a single object on a single date; this differs from the standard DetailView by accepting a year/month/day in the URL. |
Class |
|
Abstract base class for date-based views displaying a list of objects. |
Class |
|
List of objects published on a given day. |
Class |
|
List of objects published in a given month. |
Class |
|
List of objects published today. |
Class |
|
List of objects published in a given week. |
Class |
|
List of objects published in a given year. |
Class |
|
Mixin class for views manipulating date-based data. |
Class |
|
Mixin for views manipulating day-based data. |
Class |
|
Mixin for views manipulating month-based data. |
Class |
|
Mixin for views manipulating week-based data. |
Class |
|
Mixin for views manipulating year-based data. |
Function | timezone |
Return the current date in the current time zone. |
Function | _date |
Get a datetime.date object given a format string and a year, month, and day (only year is mandatory). Raise a 404 for an invalid date. |
Function | _get |
Get the next or the previous valid date. The idea is to allow links on month/day views to never be 404s by never providing a date that'll be invalid for the given view. |
Get a datetime.date object given a format string and a year, month, and day (only year is mandatory). Raise a 404 for an invalid date.
Get the next or the previous valid date. The idea is to allow links on month/day views to never be 404s by never providing a date that'll be invalid for the given view. This is a bit complicated since it handles different intervals of time, hence the coupling to generic_view. However in essence the logic comes down to: * If allow_empty and allow_future are both true, this is easy: just return the naive result (just the next/previous day/week/month, regardless of object existence.) * If allow_empty is true, allow_future is false, and the naive result isn't in the future, then return it; otherwise return None. * If allow_empty is false and allow_future is true, return the next date *that contains a valid object*, even if it's in the future. If there are no next objects, return None. * If allow_empty is false and allow_future is false, return the next date that contains a valid object. If that date is in the future, or if there are no next objects, return None.