diff --git a/apps/backend/src/services/admin/platform-config/affiliate-dash-service.ts b/apps/backend/src/services/admin/platform-config/affiliate-dash-service.ts index ed0009a6..1a559d52 100644 --- a/apps/backend/src/services/admin/platform-config/affiliate-dash-service.ts +++ b/apps/backend/src/services/admin/platform-config/affiliate-dash-service.ts @@ -72,6 +72,7 @@ function mapEffectiveAffiliateDashConfig(config: ReturnType 启用 + 映射命中优先 + BASE_URL diff --git a/apps/frontend/src/types/admin/platform-config/affiliate-dash.ts b/apps/frontend/src/types/admin/platform-config/affiliate-dash.ts index 5fa885d1..143001c4 100644 --- a/apps/frontend/src/types/admin/platform-config/affiliate-dash.ts +++ b/apps/frontend/src/types/admin/platform-config/affiliate-dash.ts @@ -7,6 +7,7 @@ export interface AdminAffiliateDashConfig { timeoutMs: number notifyUrl: string timestampToleranceSeconds: number + preferredMatchEnabled: boolean skuMapping: Record } @@ -16,6 +17,7 @@ export interface AdminAffiliateDashEffectiveConfig { timeoutMs: number notifyUrl: string timestampToleranceSeconds: number + preferredMatchEnabled: boolean hasAppKey: boolean hasAppSecret: boolean hasCallbackSecret: boolean diff --git a/docs/ affiliate_dash_发货平台/affiliate-dash对接.md b/docs/ affiliate_dash_发货平台/affiliate-dash对接.md index eebe417e..38ac9441 100644 --- a/docs/ affiliate_dash_发货平台/affiliate-dash对接.md +++ b/docs/ affiliate_dash_发货平台/affiliate-dash对接.md @@ -731,3 +731,27 @@ order_site 处理要求: - **履约配置**(`AdminPlatformFulfillmentPage`):履约路由、kuaishou-feifei 履约、kuaishou-lewan 履约 —— 通道路由与履约参数 **验证**:前端 `tsc -b --noEmit` 通过;后端未改动。 + +--- + +## 25. 履约配置页 affiliate-dash 覆盖分析(v2.10 · 已完成) + +**需求**:确认履约配置页是否也需要 affiliate-dash 相关内容(账号归平台配置页)。 + +### 分析结论 + +| 配置项 | 归属 | 现状 | +| --- | --- | --- | +| 对接凭据(appKey/appSecret/callbackSecret/baseUrl/timeout/容差) | 平台配置 | ✅ 平台配置页 affiliate-dash tab | +| 钱包 / 商品目录 / 映射测试 | 平台配置 | ✅ 平台配置页 affiliate-dash tab | +| 91 编码 → sku 映射表 | 平台配置 | ✅ 平台配置页 affiliate-dash tab | +| **履约路由**:通道开关(affiliate_dash enabled) | 履约配置 | ✅ 履约路由面板已含(ROUTING_EXECUTORS) | +| **通道优先级**(defaultExecutorPriority 含 affiliate_dash,可上移/下移) | 履约配置 | ✅ 履约路由面板已含 | +| **商品路由规则**(商品名 → affiliate_dash) | 履约配置 | ✅ 履约路由面板规则编辑器已含 | +| **指定匹配优先开关**(preferredMatchEnabled) | 平台配置 | ⚠️ 新增字段未暴露 UI → **本次已补** | + +**结论**:「账号在平台配置、路由在履约配置」的职责划分**已成立**——履约路由面板在阶段 3 就已纳入 affiliate_dash(通道开关/优先级/规则)。本次仅修复一个真实缺口:`preferredMatchEnabled`(映射命中优先,默认 true)此前只能靠默认值或环境变量,后台改不了;现已在平台配置 affiliate-dash tab 增加开关,前后端 effective/source 均透出。 + +**未新增**:履约配置页不加独立「affiliate-dash 履约面板」——feifei/lewan 有独立面板是因为履约参数多(productRules、deliveryItems 等),affiliate_dash 履约参数只有路由+优先级+规则,已覆盖,加面板属重复。 + +**验证**:前端 `tsc -b --noEmit` 通过;后端 typecheck 通过;224 测试全绿。