feat(ECR-041): OpsCMS Banner 薄写面(Write-Wave 首刀)

Admin POST/PUT + admin.cms.write/审计;C 端 GET /home/banners;首页投影回退静态 homeFeeds;migration 000051;不碰 FeedSlot/支付/UGC。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
jackyu66git
2026-08-13 19:55:27 +08:00
co-authored by Cursor
parent ad45d17dff
commit 9707b72808
35 changed files with 1203 additions and 29 deletions
+35
View File
@@ -0,0 +1,35 @@
# TEST_REPORT — ECR-041 Banner Write
**Date:** 2026-08-13
**Commit:** (pending commit)
## Commands
```bash
cd apps/api && go test ./internal/integration/ -count=1 -run 'TestOpsCMSBanner'
npm run test -w @yuxingu/user-h5 -- src/lib/homeCatalog.spec.ts
python3 scripts/repo-governance-check.py
```
## Results
| Check | Result |
|-------|--------|
| TestOpsCMSBanners (read) | PASS |
| TestOpsCMSBannerWrite | PASS |
| homeCatalog vitest (3) | PASS |
| repo-governance-check | PASS · max migration 000051 |
## AC map
| AC | Evidence |
|----|----------|
| AC-F-01 | Write test create → list/get |
| AC-F-02 | PUT active=false → C-end excludes |
| AC-F-03 | GET /home/banners contains active home |
| AC-F-04 | duplicate code → 409 |
| AC-F-05 | external link_path → 400 |
| AC-S-01/02 | 401 unauth; read-only role POST → 403 |
| AC-A-01 | audit rows create+update |
| AC-C-01/02 | H5 mapHomeBannersToFeeds + static fallback |
| AC-O-01 | no FeedSlot write routes added |