finish
This commit is contained in:
1 parent
32ae5530b6
commit
c07a2f6dae
20 files changed
+995
-61
No files matched your search
+9
-2
@@ -1,7 +1,7 @@
|
||||
from datetime import datetime
|
||||
from typing import TYPE_CHECKING, Optional
|
||||
|
||||
from sqlalchemy import DateTime, ForeignKey, Index, Integer, String, func
|
||||
from sqlalchemy import Boolean, DateTime, ForeignKey, Index, Integer, String, func
|
||||
from sqlalchemy.orm import Mapped, mapped_column, relationship
|
||||
|
||||
from app.database.session import Base
|
||||
@@ -41,6 +41,7 @@ class Video(Base):
|
||||
Index("idx_video_project_id", "project_id"),
|
||||
Index("idx_video_lyric_id", "lyric_id"),
|
||||
Index("idx_video_song_id", "song_id"),
|
||||
Index("idx_video_is_deleted", "is_deleted"),
|
||||
{
|
||||
"mysql_engine": "InnoDB",
|
||||
"mysql_charset": "utf8mb4",
|
||||
@@ -80,7 +81,6 @@ class Video(Base):
|
||||
task_id: Mapped[str] = mapped_column(
|
||||
String(36),
|
||||
nullable=False,
|
||||
unique=True,
|
||||
comment="영상 생성 작업 고유 식별자 (UUID7)",
|
||||
)
|
||||
|
||||
@@ -102,6 +102,13 @@ class Video(Base):
|
||||
comment="생성된 영상 URL",
|
||||
)
|
||||
|
||||
is_deleted: Mapped[bool] = mapped_column(
|
||||
Boolean,
|
||||
nullable=False,
|
||||
default=False,
|
||||
comment="소프트 삭제 여부 (True: 삭제됨)",
|
||||
)
|
||||
|
||||
created_at: Mapped[datetime] = mapped_column(
|
||||
DateTime,
|
||||
nullable=False,
|
||||
|
||||
Reference in new issue
Block a user