feat: Add Extraction model and seed main playlist functionality
This commit is contained in:
@@ -5,9 +5,9 @@ from sqlmodel import Field, Relationship
|
||||
from app.models.base import BaseModel
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from app.models.extraction import Extraction
|
||||
from app.models.playlist_sound import PlaylistSound
|
||||
from app.models.sound_played import SoundPlayed
|
||||
from app.models.stream import Stream
|
||||
|
||||
|
||||
class Sound(BaseModel, table=True):
|
||||
@@ -31,5 +31,5 @@ class Sound(BaseModel, table=True):
|
||||
|
||||
# relationships
|
||||
playlist_sounds: list["PlaylistSound"] = Relationship(back_populates="sound")
|
||||
streams: list["Stream"] = Relationship(back_populates="sound")
|
||||
extractions: list["Extraction"] = Relationship(back_populates="sound")
|
||||
play_history: list["SoundPlayed"] = Relationship(back_populates="sound")
|
||||
|
||||
Reference in New Issue
Block a user