Skip to content
Snippets Groups Projects
Commit 96e9bed1 authored by David Trattnig's avatar David Trattnig
Browse files

feat: init and playlist getter for item

parent ec613a74
Branches
Tags
1 merge request!35ORM-less scheduling
...@@ -256,7 +256,7 @@ class Timeslot: ...@@ -256,7 +256,7 @@ class Timeslot:
self.end = end self.end = end
self.show = show self.show = show
self.episode = episode self.episode = episode
self.playlist = Playlists(None, None, None) self.playlist = None
def get_id(self) -> int: def get_id(self) -> int:
""" """
...@@ -478,6 +478,15 @@ class PlaylistItem: ...@@ -478,6 +478,15 @@ class PlaylistItem:
self.volume = volume self.volume = volume
self.metadata = metadata self.metadata = metadata
def get_playlist(self) -> Playlist:
"""
Get the playlist of this item.
Returns:
Playlist: The associated playlist.
"""
return self.playlist
def get_position(self) -> int: def get_position(self) -> int:
""" """
Calculate the position in the playlist. Calculate the position in the playlist.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment