This commit is contained in:
2026-08-08 15:57:04 +08:00
parent d49b4128bc
commit 57fcabe740
15 changed files with 34604 additions and 25 deletions
@@ -15,10 +15,10 @@ export async function run(context) {
}
const suffix = context.marker.replace(/\D/g, '').slice(-10)
const customerId = Number(context.context?.customerId || 10001)
const customerId = id(context.context?.customerId || '10001')
const payload = {
outboundOrderId: null, oceanBookingId: Number(ocean.id), containerBookingId: null, loadingPlanId: null,
warehouseId: Number(context.createdResources?.warehouse?.id || context.context?.warehouseId || 193000000000000001),
outboundOrderId: null, oceanBookingId: ocean.id, containerBookingId: null, loadingPlanId: null,
warehouseId: id(context.createdResources?.warehouse?.id || context.context?.warehouseId || '193000000000000001'),
customerId, customerName: `服务中心链路客户-${suffix}`, carrierId: null, carrierName: `链路承运商-${suffix}`,
fleetContact: '链路车队联系人', fleetPhone: '13800000007', driverName: '链路司机', driverPhone: '13800000008',
driverIdCard: null, vehicleNo: `粤D-${suffix.slice(-6)}`, storeName: `链路门店-${suffix}`, storeContact: '链路联系人',
@@ -41,5 +41,6 @@ export async function run(context) {
context.assert(MODULE, '跨服务链路安全终态为 CANCELLED', action, cancelled?.status === 'CANCELLED', `status=${cancelled?.status || 'missing'}`, OPTIONS)
const detail = await context.request('GET', `${TRUCK}/${appointmentId}`)
const final = context.apiSuccess(MODULE, '回查跨服务链路审计历史', detail, '', OPTIONS)
context.assert(MODULE, '跨服务链路状态历史存在', detail, Array.isArray(final?.histories) && final.histories.length >= 1, `histories=${final?.histories?.length ?? 'n/a'}`, OPTIONS)
context.addCoverageGap(MODULE, 'service-center-cross-flow', '拖车预约状态历史独立查询',
'当前拖车预约 Controller 仅提供详情实体,没有公开 histories 查询字段/端点;已验证详情中的关联 ID、版本和审计时间字段', 'no-public-history-api')
}