feat: p2v_video 공유 페이지 설명에 내레이션 사용

This commit is contained in:
skkim committed 2026-10-15 16:47:39 +09:00
1 parent da99360cb7
commit 23a2ab4013
3 files changed
+13 -3

No files matched your search

+8
View File
@@ -60,6 +60,14 @@ def poster_of(ctype: str, row) -> str | None:
return row.thumbnail_url if ctype == JOB_TYPE_VIDEO else playreel_thumbnail_url(row)
def narration_text_of(ctype: str, row) -> str | None:
"""공유 설명으로 쓰는 내레이션 한 줄. 무빙 포스터만 지원하고 없으면 None."""
if ctype != JOB_TYPE_VIDEO:
return None
lines = [str(line).strip() for line in row.narration_lines or [] if line]
return " ".join(line for line in lines if line) or None
async def like_state(
session: AsyncSession, ctype: str, content_id: int, user_uuid: str | None
) -> tuple[int, bool]: