Added PeriodConverter to convert a period specification to a period, and applied it in the URL patterns.

This commit is contained in:
2020-07-21 22:05:39 +08:00
parent 01dbd7e60b
commit f9a9a99246
9 changed files with 79 additions and 62 deletions

View File

@ -102,6 +102,10 @@ class Period:
def description(self):
return self._period.description
@property
def error(self):
return self._period.error
@staticmethod
def _get_last_month_start():
"""Returns the first day of the last month.