You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
chenchuchuan
fbf2363c06
feat(edayun): 对接查询订单费用明细
POST /webApi/order/cost/v1/selectOrderCostInfoList → List<BillingDocument>
与交易明细(accountFlow/list)是两回事:
- 交易明细 = 账户流水,带余额,金额为负表示扣费
- 订单费用 = 按订单拆的报价,带应收/折扣/实付与计费重、分区
三处关键口径:
1. **金额取实付**(realPayPrice = 应收 - 折扣)。应收只是报价,
对账要以实际发生为准。三个金额都保留在 DTO 里。
2. **一个订单展开成多条**。响应是 rows → chargeDetails → feeDetails,
按计费项展开,多条记录 documentNo 相同、靠 feeName 区分。
只有汇总没有 feeDetails 时按汇总记一条。
3. **单号类型要配合**(type: 0 订单号 / 1 平台单号 / 2 追踪号)。
统一模型新增 FeeQueryNoType 枚举与 FeeQuery.noType(),
不支持的类型显式拒绝——静默按别的口径查会让对账金额对不上。
时间窗 ≤3 个月(文档约束),无单号且无时间窗时本地拒绝。
能力接口新增 WarehouseFeeCapable.orderCosts(默认抛不支持),
门面 fees().orderCosts(query)。
顺带补 BillingDocument 里遗漏的 serialNumber() / accountBalance() getter
(上一提交只加了字段没加 getter,测试编译不过)。
测试 12 个。只跑 edayun 模块:93 个全绿;yqn / xincang 未受影响。
Co-Authored-By: Claude <noreply@anthropic.com>
|
1 week ago |
| .. |
|
java/common/ecommerce/edayun
|
feat(edayun): 对接查询订单费用明细
|
1 week ago |