docs(model): Period.kind 现状澄清——恒为 week 的留门字段,月粒度由 year/month 合成
排查结论(第 6 轮遗留决策):kind 全链无读取方(后端不按其过滤,顶栏月粒度用 year/month 列, 前端 weekly 行的 kind 是另一条「行类型」线,与此无关);但删它要动写入+to_dict+历史库兼容, 收益小于风险——裁决保留列、堵注释与文档的歧义(README 原「年/月/周」误导)。main
parent
3b37e7440a
commit
f872eee367
|
|
@ -488,7 +488,7 @@ python scripts/legacy/add_entry_date.py --force # 全部重算
|
|||
|
||||
```
|
||||
# 项目管理(长期重点项目)
|
||||
Period(周期: 年/月/周, sort_key)
|
||||
Period(周期: 一行=一个自然周, kind 恒为 week——月粒度由 year/month 列合成, sort_key 全排序)
|
||||
└── Project(分类, 负责人 owners[0], 其他负责人, 团队成员, 状态, 重点标记, 进度, 标签)
|
||||
├── Task(子任务)
|
||||
└── Update(执行情况: 正文, 摘要, 进度, 状态, 风险, 下一步, 来源, 原文)
|
||||
|
|
|
|||
|
|
@ -192,7 +192,7 @@ class Period(Base):
|
|||
|
||||
id: Mapped[int] = mapped_column(Integer, primary_key=True)
|
||||
label: Mapped[str] = mapped_column(String(64), nullable=False) # 8月第4周
|
||||
kind: Mapped[str] = mapped_column(String(16), default="week", nullable=False) # week|month
|
||||
kind: Mapped[str] = mapped_column(String(16), default="week", nullable=False) # 恒为 week:月粒度由 year/month 合成,此列只是留门(无任何读取方)
|
||||
year: Mapped[int] = mapped_column(Integer, nullable=False)
|
||||
month: Mapped[int] = mapped_column(Integer, nullable=False)
|
||||
week: Mapped[int] = mapped_column(Integer, default=0, nullable=False) # 月视图为 0
|
||||
|
|
|
|||
Loading…
Reference in New Issue