Add season codes and overview page.

This commit is contained in:
2019-01-12 15:02:21 +01:00
parent 30bab3e651
commit 29989b7e4e
6 changed files with 48 additions and 11 deletions

View File

@@ -78,6 +78,7 @@ class Season:
description: str
start: datetime.date
end: datetime.date
code: str
@classmethod
def from_form(cls, form):
@@ -104,5 +105,7 @@ class Season:
except Exception:
raise INVALID_STR.format('end')
self = cls(id, game, description, start, end)
code = form.get('code', None)
self = cls(id, game, description, start, end, code)
return self