views.generic.dates.DayMixin.get_previous_day()

get_previous_day(date) [source] Returns a date object containing the previous valid day. This function can also return None or raise an Http404 exception, depending on the values of allow_empty and allow_future.

views.generic.dates.DayMixin.get_next_day()

get_next_day(date) [source] Returns a date object containing the next valid day after the date provided. This function can also return None or raise an Http404 exception, depending on the values of allow_empty and allow_future.

views.generic.dates.DayMixin.get_day_format()

get_day_format() [source] Returns the strftime() format to use when parsing the day. Returns day_format by default.

views.generic.dates.DayMixin.get_day()

get_day() [source] Returns the day for which this view will display data, as a string. Tries the following sources, in order: The value of the DayMixin.day attribute. The value of the day argument captured in the URL pattern. The value of the day GET query argument. Raises a 404 if no valid day specification can be found.

views.generic.dates.DayMixin.day_format

day_format The strftime() format to use when parsing the day. By default, this is '%d'.

views.generic.dates.DayMixin.day

day Optional The value for the day, as a string. By default, set to None, which means the day will be determined using other means.

views.generic.dates.DayMixin

class DayMixin [source] A mixin that can be used to retrieve and provide parsing information for a day component of a date. Methods and Attributes day_format The strftime() format to use when parsing the day. By default, this is '%d'. day Optional The value for the day, as a string. By default, set to None, which means the day will be determined using other means. get_day_format() [source] Returns the strftime() format to use when parsing the day. Returns day_format by default

views.generic.dates.DayArchiveView

class DayArchiveView [source] A day archive page showing all objects in a given day. Days in the future throw a 404 error, regardless of whether any objects exist for future days, unless you set allow_future to True. Ancestors (MRO) django.views.generic.list.MultipleObjectTemplateResponseMixin django.views.generic.base.TemplateResponseMixin django.views.generic.dates.BaseDayArchiveView django.views.generic.dates.YearMixin django.views.generic.dates.MonthMixin django.views.generic.dates.DayMi

views.generic.dates.DateMixin.get_date_field()

get_date_field() [source] Returns the name of the field that contains the date data that this view will operate on. Returns date_field by default.

views.generic.dates.DateMixin.get_allow_future()

get_allow_future() [source] Determine whether to include “future” objects on this page, where “future” means objects in which the field specified in date_field is greater than the current date/time. Returns allow_future by default.