Files
solution-erp/.claude/workflows/runs/2026-07-29-S161-khkk-w1-schema/run.md
2026-07-29 19:44:56 +07:00

27 lines
4.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# RUN — W1 KHKK: Schema Mig 69 + Permission + Designer type-10 (S161, 2026-07-29)
> **Wave đầu tiên của DRY-RUN TOÀN TRÌNH** (plan cha `../2026-07-29-S160-khkk-dryrun-plan/plan-cha-dry-run-toan-trinh-29-07-2026.md`).
> Spec thi công: `../2026-07-29-S160-khkk-dryrun-plan/spec-wave-w1-schema-designer-29-07-2026.md` (+ spec cũ `../2026-07-28-S157-ke-hoach-ky-ket-hd/spec-ke-hoach-ky-ket-hd-28-07-2026.md` §2.2 bảng chi tiết).
> **Gate 5-anchor: PASS 5/5 @S161** (slot 10 trống `ApprovalWorkflowsV2/ApprovalWorkflow.cs:53-67` · `MenuKeys.cs:41` const+comment · KeHoachKyKet ∉ All · `AuthorizePolicyRegressionTests.cs:138-139` lưới sống · `DbInitializer.cs:1779-1786` Khkk 7 key).
> **3 quyết owner @S161:** (1) mã phiếu `KHKK/{YYYY}/{Seq:D3}` OK · (2) "Bỏ MB" — dry-run cấm HĐ MuaBan, codegen giữ chờ format thay · (3) GĐ4 1-mốc (không đụng W1).
## taskList snapshot
| # | Stage | Vai / cách | Trạng thái |
|---|---|---|---|
| 1 | Đợt-1a BE: Domain 7 entity + 3 enum + ApplicableType=10 + EF Config ×7 + DbSets + **Mig 69** 3-file (apply 2 DB) + MenuKeys All+= + DbInitializer UPGRADE-if-exists (13/13 role) + CodeGen KHKK + 3 site AWV2AdminFeatures | hmw `implementer-backend` | [x] 3 chặng: lane-1 `wf_7d6fb81b-640` chết #53 sau Domain (8 entity + type-10 + 4/7 config) → lane-2 `wf_f8c806d2-5a3` cũng chết #53 NHƯNG sub-md 6.2KB ghi-trong-lúc-làm cứu trọn (audit 0-lệch + 3 config + DbSets + MenuKeys:179 + **Mig 69 `20260729122015` 3-file, apply 2 DB, sys.tables=96**, grep-proof trong sub-md) → **lead solo đuôi @S161**: seeder `SeedKeHoachKyKetAccessAsync` UPGRADE-if-exists+CanDelete (call sau revoke) + `ContractSigningPlanCodeGenerator` KHKK/{YYYY}/{Seq:D3} + DI + 3 site AWV2Admin (count/retained/orphan mirror VehicleBooking). **`dotnet build` 0W/0E 47s** |
| 2 | Đợt-1b FE: Designer type-10 `ApprovalWorkflowsV2Page.tsx` (TYPE_CODE_TO_INT + option + ẩn 2 checkbox early-finalize khi type=10) | hmw `implementer-frontend` | [x] `wf_7d6fb81b-640` lane-2 CLEAN — +67/9, containment 2-LỚP render+payload; **lead verify build tươi PASS** (bundle `index-iNZq9job`; diagnostics giữa-agent = stale #68); harvest diary xong. Cờ đỏ: type-10 chưa có đường sidebar (allowlist `Layout.tsx:162-168` — cả type-3 xưa nay cũng vậy, đúng spec "menu KHÔNG đổi") |
| 3 | Đợt-2a: schema test + codegen format test (`ContractSigningPlanSchemaTests` + `SigningPlanCodeGenerator_Format_KhkkYearSeqD3`, N ≥ 2) | hmw `test-specialist` | [x] `wf_a95c9909-14b`**4 test** (vượt sàn 2) + fault-inject 2 chiều chứng răng + bắt LỆCH prompt-vs-đĩa (LevelOpinion CỐ Ý không filter → assert thành invariant); vai chết #53 lúc đợi full-suite → lead chạy tươi + điền §2/§4 on-behalf |
| 4 | Đợt-2b: design-review Mig 69 TRƯỚC deploy (reversible Down · snapshot drift · FK/index) | hmw `database-agent` | [x] cùng wf — **PASS 8/8 + DB11, 0 blocker** (đo sys.foreign_keys/filter_definition; parity 2 DB tuyệt đối; Down script atomic sạch; IX superset khuôn PE; 4 advisory wave-sau) — `sub-database-agent-1.md` 21KB |
| 5 | Lead: build ×2 + `dotnet test` + sqlcmd 89→96 + Down-script sạch + acceptance §③-B sweep | lead | [x] build BE 0W/0E 47s + FE build tươi PASS · test **566/0** (562+4 ≥ sàn 564) · sys.tables 96 ×2 DB · Down script-proof · CÒN 2 vế prod-side @stage-7: đo-CỜ policy sau seed prod + Designer tạo type-10 3-Bước |
| 6 | Reviewer adversarial diff (schema mig >50 LOC — bắt buộc trước commit) | `reviewer` | [!] ĐANG CHẠY nền — focus: revoker-2-chiều seeder · 3-site mirror · FE containment · boundary 0-diff ContractCodeGenerator/CWS |
| 7 | Commit + push + cicd-monitor 3-chân-kiềng (CI PASS · mig 69 prod · menu 142 giữ) | lead + `cicd-monitor` | [ ] |
## Ràng buộc mang theo
- 🔴 Seeder = **UPGRADE-if-exists khuôn `SeedProcurementMasterAccessAsync:2367-2374` + mở rộng vế CanDelete**, chạy SAU revoke (mirror `:2098-2101`) — KHÔNG insert (F-S1, 403 giết dry-run) · CẤM SQL tay (#84).
- 🔴 Acceptance đo CỜ không đếm ROW (F-04) · UNIQUE filtered WHERE IsDeleted=0 (#57) · enum bắt đầu 1 không 0 (falsy JS) · loose-Guid không FK vật lý sang PE/Supplier (convention Mig 49).
- 🔴 Lead commit SAU reviewer — worker KHÔNG commit/push.
## Stages
(cập nhật theo tiến độ)