贴标申请,仓储转运
This commit is contained in:
@@ -1775,7 +1775,7 @@ paths:
|
||||
/api/pda/v1/last-leg/return-receipts/confirm:
|
||||
post:
|
||||
summary: PDA 确认退货签收
|
||||
description: PDA 仅能操作绑定海外仓。startedBy 记录通过退货单号或 SKU 候选进入;trackingNo 为本次包裹可选快递单号。按预报可签收数量校验、禁止超收;每次成功确认创建唯一签收单及仓储计费批次。全部预报 SKU 数量吻合时自动 COMPLETED。
|
||||
description: PDA 仅能操作绑定海外仓。startedBy 记录通过退货单号或 SKU 候选进入;按 PALLET、BOX、PARCEL 选择现场实物维度。托盘必须提交托盘码、长宽高和重量并计算体积;箱子可散装,也可额外绑定托盘;包裹只需提交包裹/快递单号。按预报可签收数量校验、禁止超收;每次成功确认创建唯一签收单及仓储计费批次。全部预报 SKU 数量吻合时自动 COMPLETED。
|
||||
security: [{ bearerAuth: [] }]
|
||||
requestBody: { required: true, content: { application/json: { schema: { $ref: '#/components/schemas/ReturnReceiptConfirm' } } } }
|
||||
responses: { '200': { description: 签收结果及自动完成状态 }, '409': { description: 超收、错绑或幂等键冲突 } }
|
||||
@@ -2026,7 +2026,13 @@ components:
|
||||
returnNo: { type: string, maxLength: 128 }
|
||||
trackingNo: { type: string, nullable: true, maxLength: 128, description: '本次签收包裹有快递面单时扫描绑定;没有时为空' }
|
||||
startedBy: { type: string, enum: [RETURN_NO, SKU], description: '本次通过退货单号查询或 SKU 候选开始签收' }
|
||||
cartonMark: { type: string, nullable: true, maxLength: 128, description: PDA 实际绑定的箱号;不传时由系统生成 }
|
||||
unitType: { type: string, enum: [PALLET, BOX, PARCEL], default: PALLET, description: 本次签收实物维度 }
|
||||
unitCode: { type: string, nullable: true, maxLength: 128, description: 托盘码或包裹/快递单号;箱子不传时由系统生成内部箱号 }
|
||||
palletCode: { type: string, nullable: true, maxLength: 128, description: 箱子可选的托盘绑定码;托盘类型下与 unitCode 相同 }
|
||||
length: { type: number, nullable: true, exclusiveMinimum: true, description: 托盘长度,CM;托盘类型必填 }
|
||||
width: { type: number, nullable: true, exclusiveMinimum: true, description: 托盘宽度,CM;托盘类型必填 }
|
||||
height: { type: number, nullable: true, exclusiveMinimum: true, description: 托盘高度,CM;托盘类型必填 }
|
||||
weight: { type: number, nullable: true, exclusiveMinimum: true, description: 托盘重量,KG;托盘类型必填 }
|
||||
idempotencyKey: { type: string, maxLength: 255 }
|
||||
items:
|
||||
type: array
|
||||
@@ -2038,6 +2044,7 @@ components:
|
||||
properties:
|
||||
skuCode: { type: string, maxLength: 128 }
|
||||
receivedQuantity: { type: integer, minimum: 1 }
|
||||
boxCount: { type: integer, nullable: true, minimum: 1, description: 托盘或箱子签收时该 SKU 对应箱数,包裹签收不填 }
|
||||
ReturnInventoryMerge:
|
||||
type: object
|
||||
required: [returnNos, items, length, width, height, weight, idempotencyKey]
|
||||
|
||||
@@ -858,9 +858,11 @@ components:
|
||||
remark: { type: string, maxLength: 1000, nullable: true }
|
||||
DispatchPick:
|
||||
type: object
|
||||
required: [positionId, packages, productQuantity, idempotencyKey]
|
||||
description: 普通库存提交positionId;原生退货换标箱提交cartonMark、positionId为空、packages=1,productQuantity必须与箱快照一致。两类来源互斥。
|
||||
required: [packages, productQuantity, idempotencyKey]
|
||||
properties:
|
||||
positionId: { type: string, pattern: '^[0-9]+$' }
|
||||
positionId: { type: string, pattern: '^[0-9]+$', nullable: true }
|
||||
cartonMark: { type: string, maxLength: 255, description: 本排车来源的系统箱唛 }
|
||||
packages: { type: integer, format: int64, minimum: 1 }
|
||||
productQuantity: { type: integer, format: int64, minimum: 0 }
|
||||
idempotencyKey: { type: string, minLength: 1, maxLength: 255 }
|
||||
|
||||
@@ -0,0 +1,157 @@
|
||||
openapi: 3.0.3
|
||||
info:
|
||||
title: 退货合箱计划与箱级上架
|
||||
version: 1.0.0
|
||||
description: 散SKU查询客户全部同仓PARCEL可用库存;箱合并精确指定来源箱唛并扫描已有目标箱。托盘仅为可选载体。合箱不新增订单货量。
|
||||
security: [{ bearerAuth: [] }]
|
||||
paths:
|
||||
/api/platform/v1/last-leg/return-packing-plans:
|
||||
get:
|
||||
summary: 合箱计划分页
|
||||
description: return-inventory:list;page/size/status/planNo 查询,planNo 去除首尾空格后按字面包含匹配,统计与分页使用相同条件。每条计划返回 createdAt 和 completedAt(实际合箱完成时间);已完成计划 resultCartons 返回实际箱唛、SKU数量及当前库位、载体托盘。完成时间不使用箱子的 putawayAt,原箱多次合箱时仍显示本次计划完成时间。
|
||||
parameters:
|
||||
- { name: planNo, in: query, schema: { type: string, maxLength: 128 }, description: 合箱计划号,支持部分编号查询 }
|
||||
- { name: customerId, in: query, schema: { type: string, maxLength: 64 }, description: 客户筛选 }
|
||||
- { name: overseasWarehouseId, in: query, schema: { type: string, maxLength: 64 }, description: 海外仓筛选 }
|
||||
- { name: skuCode, in: query, schema: { type: string, maxLength: 128 }, description: 计划箱内 SKU,支持部分编码;多条件同时匹配 }
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
post:
|
||||
summary: 创建并锁定来源库存
|
||||
description: return-inventory:list + lastleg:inventory:manage;同客户同仓已签收订单,BOX精确锁来源箱全部SKU,SKU只锁散件指定数量。
|
||||
requestBody: { required: true, content: { application/json: { schema: { $ref: '#/components/schemas/Create' } } } }
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/platform/v1/last-leg/return-packing-plans/{planNo}/review:
|
||||
post:
|
||||
summary: 审核并推送PDA
|
||||
description: return-inventory:list + lastleg:inventory:manage;PENDING_REVIEW→READY。
|
||||
parameters: [{ name: planNo, in: path, required: true, schema: { type: string } }]
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/platform/v1/last-leg/return-packing-plans/{planNo}/cancel:
|
||||
post:
|
||||
summary: 取消并释放本计划预占
|
||||
description: return-inventory:list + lastleg:inventory:manage;仅待审或READY,完成不可取消。
|
||||
parameters: [{ name: planNo, in: path, required: true, schema: { type: string } }]
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/pda/v1/last-leg/return-inventory/packing/plans:
|
||||
get:
|
||||
summary: 绑定仓已审核合箱计划
|
||||
description: lastleg:pda:operate + ROLE_OVERSEAS_WAREHOUSE_PDA_OPERATOR;只返回READY任务。
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/pda/v1/last-leg/return-inventory/packing/plans/{planNo}:
|
||||
get:
|
||||
summary: 读取精确锁定的来源和数量
|
||||
description: 绑定仓范围;sources含来源箱逐SKU锁定件数,boxes含汇总数量。
|
||||
parameters: [{ name: planNo, in: path, required: true, schema: { type: string } }]
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/pda/v1/last-leg/return-inventory/packing/plans/{planNo}/complete:
|
||||
post:
|
||||
summary: 多箱分配并完成计划
|
||||
description: SKU目标总量须等于锁定量。BOX先选择新增目标箱或扫描已有目标箱,sourceDeductions逐来源箱及SKU指定实际扣除量(不超过锁定量),未使用预占释放;目标原库存不扣减,新箱须填写箱规并生成系统箱唛。全事务、同载荷重放标签快照。
|
||||
parameters: [{ name: planNo, in: path, required: true, schema: { type: string } }]
|
||||
requestBody: { required: true, content: { application/json: { schema: { $ref: '#/components/schemas/Complete' } } } }
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/pda/v1/last-leg/return-inventory/cartons/{cartonMark}:
|
||||
get:
|
||||
summary: 扫描可用来源或目标箱
|
||||
description: 仅同仓AVAILABLE实物箱,PARCEL不作为箱选择。
|
||||
parameters: [{ name: cartonMark, in: path, required: true, schema: { type: string } }]
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/pda/v1/last-leg/return-inventory/cartons/merge-boxes:
|
||||
post:
|
||||
summary: 来源箱并入已有目标箱
|
||||
description: 同客户同仓,已有目标箱须与来源不同。sourceDeductions指定各来源箱SKU实际扣除量;未传则整箱移动。targetCartonMark为空时新增系统箱,必须填写箱规。保留逐退货单来源追溯。
|
||||
requestBody: { required: true, content: { application/json: { schema: { $ref: '#/components/schemas/BoxMerge' } } } }
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/pda/v1/last-leg/return-inventory/cartons/pack:
|
||||
post:
|
||||
summary: 散SKU分配多个新箱
|
||||
description: 同客户全部散件来源,所有新箱原子提交;同键异内容拒绝。
|
||||
requestBody: { required: true, content: { application/json: { schema: { $ref: '#/components/schemas/Pack' } } } }
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
/api/pda/v1/last-leg/return-inventory/cartons/{cartonMark}/putaway:
|
||||
post:
|
||||
summary: 退货箱扫码库位上架
|
||||
description: 绑定仓有效非虚拟库位、AVAILABLE箱且无预占;palletCode选填。返回库位、托盘、上架时间,不计为普通头程新收货。
|
||||
parameters: [{ name: cartonMark, in: path, required: true, schema: { type: string } }]
|
||||
requestBody: { required: true, content: { application/json: { schema: { $ref: '#/components/schemas/Putaway' } } } }
|
||||
responses: { '200': { description: 业务响应信封 code为200成功,A0400/A0404/A0409校验或状态错误,requestId及traceId保留 }, '403': { description: 权限或角色不符 } }
|
||||
components:
|
||||
securitySchemes:
|
||||
bearerAuth: { type: http, scheme: bearer, bearerFormat: JWT }
|
||||
schemas:
|
||||
CartonMergeHistory:
|
||||
type: object
|
||||
description: 箱号详情 mergeHistory 按时间倒序显示实际合入及合出数量,原有目标库存不计入本次合箱数量;历史未关联计划号时 planNo 为空。
|
||||
properties:
|
||||
planNo: { type: string, nullable: true }
|
||||
sourceCartonMark: { type: string }
|
||||
targetCartonMark: { type: string }
|
||||
returnNo: { type: string }
|
||||
skuCode: { type: string }
|
||||
quantity: { type: integer, format: int64 }
|
||||
createdAt: { type: string, format: date-time }
|
||||
Item:
|
||||
type: object
|
||||
required: [skuCode, quantity]
|
||||
properties:
|
||||
skuCode: { type: string, maxLength: 128 }
|
||||
quantity: { type: integer, format: int64, minimum: 1 }
|
||||
Box:
|
||||
type: object
|
||||
properties:
|
||||
items: { type: array, items: { $ref: '#/components/schemas/Item' }, maxItems: 100 }
|
||||
targetCartonMark: { type: string, maxLength: 128, description: BOX模式已有目标箱 }
|
||||
length: { type: number, exclusiveMinimum: true, minimum: 0, description: cm }
|
||||
width: { type: number, exclusiveMinimum: true, minimum: 0, description: cm }
|
||||
height: { type: number, exclusiveMinimum: true, minimum: 0, description: cm }
|
||||
weight: { type: number, exclusiveMinimum: true, minimum: 0, description: kg }
|
||||
Create:
|
||||
type: object
|
||||
required: [returnNos, mode, boxes, idempotencyKey]
|
||||
properties:
|
||||
returnNos: { type: array, minItems: 1, maxItems: 100, items: { type: string } }
|
||||
mode: { type: string, enum: [SKU, BOX] }
|
||||
sourceCartonMarks: { type: array, maxItems: 500, items: { type: string } }
|
||||
boxes: { type: array, minItems: 1, maxItems: 100, items: { $ref: '#/components/schemas/Box' } }
|
||||
remark: { type: string, maxLength: 1000 }
|
||||
idempotencyKey: { type: string, maxLength: 255 }
|
||||
Complete:
|
||||
type: object
|
||||
required: [boxes, idempotencyKey]
|
||||
properties:
|
||||
boxes: { type: array, minItems: 1, maxItems: 100, items: { $ref: '#/components/schemas/Box' } }
|
||||
idempotencyKey: { type: string, maxLength: 255 }
|
||||
sourceDeductions: { type: array, maxItems: 1000, items: { $ref: '#/components/schemas/SourceDeduction' } }
|
||||
SourceDeduction:
|
||||
type: object
|
||||
required: [cartonMark, skuCode, quantity]
|
||||
properties:
|
||||
cartonMark: { type: string }
|
||||
skuCode: { type: string }
|
||||
quantity: { type: integer, format: int64, minimum: 1 }
|
||||
Pack:
|
||||
allOf:
|
||||
- { $ref: '#/components/schemas/Complete' }
|
||||
- type: object
|
||||
required: [returnNos]
|
||||
properties:
|
||||
returnNos: { type: array, minItems: 1, maxItems: 100, items: { type: string } }
|
||||
BoxMerge:
|
||||
type: object
|
||||
required: [sourceCartonMarks, idempotencyKey]
|
||||
properties:
|
||||
sourceCartonMarks: { type: array, minItems: 1, maxItems: 100, items: { type: string } }
|
||||
targetCartonMark: { type: string }
|
||||
idempotencyKey: { type: string, maxLength: 255 }
|
||||
sourceDeductions: { type: array, maxItems: 1000, items: { $ref: '#/components/schemas/SourceDeduction' } }
|
||||
length: { type: number, minimum: 0, exclusiveMinimum: true }
|
||||
width: { type: number, minimum: 0, exclusiveMinimum: true }
|
||||
height: { type: number, minimum: 0, exclusiveMinimum: true }
|
||||
weight: { type: number, minimum: 0, exclusiveMinimum: true }
|
||||
Putaway:
|
||||
type: object
|
||||
required: [locationCode, idempotencyKey]
|
||||
properties:
|
||||
locationCode: { type: string, maxLength: 128 }
|
||||
palletCode: { type: string, maxLength: 128 }
|
||||
idempotencyKey: { type: string, maxLength: 255 }
|
||||
Reference in New Issue
Block a user