MCPcopy
hub / github.com/django/django / get_week

Method get_week

django/views/generic/dates.py:184–195  ·  view source on GitHub ↗

Return the week for which this view should display data.

(self)

Source from the content-addressed store, hash-verified

182 return self.week_format
183
184 def get_week(self):
185 """Return the week for which this view should display data."""
186 week = self.week
187 if week is None:
188 try:
189 week = self.kwargs["week"]
190 except KeyError:
191 try:
192 week = self.request.GET["week"]
193 except KeyError:
194 raise Http404(_("No week specified"))
195 return week
196
197 def get_next_week(self, date):
198 """Get the next valid week."""

Callers 1

get_dated_itemsMethod · 0.80

Calls 1

Http404Class · 0.90

Tested by

no test coverage detected