|
@@ -0,0 +1,54 @@
|
|
|
|
|
+# 商城-会员批次 · 开工包(18 SC)
|
|
|
|
|
+> 归属:契约补建计划 P0「商城-会员」· 生成 2026-11-07 01:2x
|
|
|
|
|
+> 数据源:sc-key-map.md(origin/cfclub,O-8 归一后 241 全量登记)· 端点核对:cfc-backend controller 源码(origin/cfclub 工作树)
|
|
|
|
|
+
|
|
|
|
|
+## 批次定位
|
|
|
|
|
+商品 → 订单 → 支付/退款 → 优惠券 → 会员权益/续费,覆盖家长/商品服务商/平台运营/游客/跨角色五视角;本批 18 个 SC 均无合法能力键(台账「对应能力键」列全为 `—`),需先定契约才能 `--add-task` 入池。**按 O-7 裁决:契约核对 = 文档核对 + 端点比对(防假 RED),本批端点已全部核验存在(见下表),无真实现缺口 → 非研发实现型 RED,产出契约文档后转测试侧(TR-8)补契约 JUnit + 三类流执行证据。**
|
|
|
|
|
+
|
|
|
|
|
+## 端点核验(18/18 已实现,0 缺失)
|
|
|
|
|
+
|
|
|
|
|
+| SC | 角色 | 场景标题 | 对应端点(origin/cfclub 工作树) | 核验 |
|
|
|
|
|
+|----|------|----------|-------------------------------|------|
|
|
|
|
|
+| SC-A-12 | 平台运营 | 订单/退款人工处理 | `ProductOrderController` `/api/product/order/refund/apply`、`/activity/audit`;`PackagePaymentController` `/api/payment/orders/{orderId}/cancel` | ✅ |
|
|
|
|
|
+| SC-A-17 | 平台运营 | 优惠券/活动配置管理 | `CouponController` `/api/coupon/available-templates`、`/join-rules`;`CouponGiftController` | ✅ |
|
|
|
|
|
+| SC-G-05 | 游客 | 浏览商城/文章(未登录受限) | `ProductController` `/api/product/list`、`/detail`(游客可读,下单须登录由 JwtInterceptor 拦截) | ✅ |
|
|
|
|
|
+| SC-P-52 | 家长 | 商品浏览/搜索 | `ProductController` `/api/product/list`、`/detail`、`/spec/map` | ✅ |
|
|
|
|
|
+| SC-P-53 | 家长 | 商品详情 | `ProductController` `/api/product/detail`、`/related-products` | ✅ |
|
|
|
|
|
+| SC-P-55 | 家长 | 订单支付 | `ProductOrderController` `/api/product/order/create`、`/pay`;`PackagePaymentController` `/api/payment/create`、`/wechat/params` | ✅ |
|
|
|
|
|
+| SC-P-56 | 家长 | 订单查询/退款 | `ProductOrderController` `/api/product/order/my`、`/detail`、`/refund/apply` | ✅ |
|
|
|
|
|
+| SC-P-57 | 家长 | 优惠券使用 | `CouponController` `/api/coupon/claim`、`/apply`、`/exchange`、`/checkout-list` | ✅ |
|
|
|
|
|
+| SC-P-59 | 家长 | 会员权益查看 | `MembershipController` `/api/membership/levels`、`/my`、`/current`、`/can-use` | ✅ |
|
|
|
|
|
+| SC-P-60 | 家长 | 会员续费 | `MembershipController` `/api/membership/upgrade`、`/orders/continue`、`/plans` | ✅ |
|
|
|
|
|
+| SC-P-75 | 家长 | 优惠券领取(活动/分享) | `CouponController` `/api/coupon/claim`;`CouponGiftController` | ✅ |
|
|
|
|
|
+| SC-P-80 | 家长 | 订阅/会员退款与发票 | `MembershipController` `/api/membership/orders`、`/upgrade-records`;`PackagePaymentController` `/api/payment/apply` | ✅ |
|
|
|
|
|
+| SC-S-02 | 商品服务商 | 商品管理(上架/编辑) | `ProductController` `/api/product/create`、`/update`、`/shelve`、`/my` | ✅ |
|
|
|
|
|
+| SC-S-03 | 商品服务商 | 订单处理(发货) | `ProductOrderController` `/api/product/order/vendor`、`/ship`、`/confirm` | ✅ |
|
|
|
|
|
+| SC-S-04 | 商品服务商 | 订单核销(到店) | `ProductOrderController` `/api/product/order/vendor-confirm`、`/activity/sign-in` | ✅ |
|
|
|
|
|
+| SC-S-06 | 商品服务商 | 售后/退款处理 | `AfterSalesController` `/api/shop/after-sales/create`、`/list`、`/detail`;`ProductOrderController` `/refund/apply` | ✅ |
|
|
|
|
|
+| SC-X-07 | 跨角色 | 商城履约闭环 | `ProductOrderController` `/create`→`/pay`→`/ship`→`/confirm` 全链路 + `handlePaymentSuccess`/`notify` 回调 | ✅ |
|
|
|
|
|
+| SC-X-12 | 跨角色 | 会员权益闭环 | `MembershipController` `/levels`→`/upgrade`→`/orders`→`/can-use` 全链路 + `notify` 回调 | ✅ |
|
|
|
|
|
+
|
|
|
|
|
+**结论**:18/18 端点已实现(0 缺失)→ 无真实现缺口,不建伪实现任务(O-7 裁决「非研发实现型 RED」)。契约文档与映射入池后转测试侧 TR-8 补契约 JUnit + 三类流证据。
|
|
|
|
|
+
|
|
|
|
|
+## 建议能力键(契约定稿后按 O-2 方案 A 映射)
|
|
|
|
|
+
|
|
|
|
|
+- `product.browse`(SC-P-52 / SC-P-53 / SC-G-05)
|
|
|
|
|
+- `order.pay`(SC-P-55)
|
|
|
|
|
+- `order.refund`(SC-P-56 / SC-S-06 / SC-A-12)
|
|
|
|
|
+- `coupon.use`(SC-P-57 / SC-P-75)
|
|
|
|
|
+- `membership.view`(SC-P-59)
|
|
|
|
|
+- `membership.renew`(SC-P-60 / SC-P-80)
|
|
|
|
|
+- `product.manage`(SC-S-02)
|
|
|
|
|
+- `order.ship`(SC-S-03 / SC-S-04)
|
|
|
|
|
+- `order.fulfill`(SC-X-07)
|
|
|
|
|
+- `membership.fulfill`(SC-X-12)
|
|
|
|
|
+- `admin.order.manual`(SC-A-12)
|
|
|
|
|
+- `admin.coupon.config`(SC-A-17)
|
|
|
|
|
+
|
|
|
|
|
+> 注:以上为**建议映射**(防假 RED 端点核验用),非最终契约键;契约文档定稿时须逐条对齐 `docs/superpowers/api/API_REFERENCE.md` 与 `tests/test-cases/*.md` 派生用例,避免键名与既有契约冲突。
|
|
|
|
|
+
|
|
|
|
|
+## 待办(O-7 授权节奏)
|
|
|
|
|
+
|
|
|
|
|
+1. 契约文档定稿(API_REFERENCE 4.x 增补「商城-会员」接口范围 + 契约缺口映射)→ 合入 origin/cfclub
|
|
|
|
|
+2. 测试侧 TR-8 登记:补契约 JUnit + 三类流执行证据
|
|
|
|
|
+3. 下一批「家庭-成员 15 SC」照此节奏滚动
|