diff --git a/server.py b/server.py index 94c99bb..1febd6e 100644 --- a/server.py +++ b/server.py @@ -3,6 +3,7 @@ import re import logging import infoboard +from datetime import date from infoboard.video import Video from infoboard.videoplayer import VideoPlayer from infoboard.watcher import Watcher @@ -46,7 +47,9 @@ def process_schedule(self, schedule): pass def get_playlist(self): - return [video.filename for video in self.videos] + today = date.today() + return [video.filename for video in self.videos + if video.start_date <= today and video.end_date >= today] if __name__ == "__main__":