feat(web): 立项新增 基调/结局/视角 三字段(书级常量入 stable_core 缓存前缀)
灵感计划 §3④ + §4 D 枚举决策: - projects 表加 tone/ending_type/narrative_pov(Text nullable、无 CHECK,同 genre/structure; 迁移 e5f6a7b8c9d0 nullable 免 backfill)。 - ProjectCreateRequest/ProjectResponse + domain ProjectCreate/ProjectView 全链路透传(snake_case)。 - 完整 stable_core 链路:ProjectSpecView + SqlProjectSpecRepo.spec + _build_spec_section 渲染进 「作品蓝本」块——书级常量随书稳定,字节稳定守缓存前缀不变量 #9,绝不入 volatile。 - 前端 wizard.ts 三字段 + 预设数组 TONES/ENDING_TYPES/NARRATIVE_POVS + ProjectWizard 控件与确认页回显。 - 契约变更已 pnpm gen:api + memory/contracts.md 登记。
This commit is contained in:
@@ -48,6 +48,10 @@ class Project(UuidPk, TimestampedMixin, Base):
|
||||
theme: Mapped[str | None] = mapped_column(Text)
|
||||
selling_points: Mapped[list[Any]] = mapped_column(JSONB, server_default=text("'[]'"))
|
||||
structure: Mapped[str | None] = mapped_column(Text)
|
||||
# 立项书级常量(灵感④)——同 genre/structure:Text nullable、无 CHECK(枚举约束留前端预设)。
|
||||
tone: Mapped[str | None] = mapped_column(Text)
|
||||
ending_type: Mapped[str | None] = mapped_column(Text)
|
||||
narrative_pov: Mapped[str | None] = mapped_column(Text)
|
||||
|
||||
|
||||
class Character(UuidPk, CreatedAt, Base):
|
||||
|
||||
Reference in New Issue
Block a user