Additional buttons and infos on episode page.

This commit is contained in:
2019-03-03 11:44:17 +01:00
parent aa1610f1b7
commit 7339c15b1e
4 changed files with 94 additions and 12 deletions

View File

@@ -113,6 +113,10 @@ class Episode:
end: Union[datetime.datetime, Rational]
code: str
@property
def playtime(self):
return self.end - self.start
def __post_init__(self):
if isinstance(self.date, str):
self.date = datetime.datetime.strptime(self.date, util.DATE_FMT).date()