完善财务费用来源与柜级分摊
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
openapi: 3.0.3
|
||||
info: { title: Firstleg Container Fee Allocation API, version: 1.0.0 }
|
||||
paths:
|
||||
/api/platform/v1/loading-plans/{loadingPlanId}/fee-details/allocation-groups:
|
||||
post:
|
||||
summary: 原子创建柜级公共费用分摊组
|
||||
description: 客户、订单必填;入仓ID与入仓码同时填写或同时留空。各分摊金额必须大于0且合计等于费用总额。
|
||||
security: [{ bearerAuth: [] }]
|
||||
parameters: [{ $ref: '#/components/parameters/LoadingPlanId' }]
|
||||
requestBody: { required: true, content: { application/json: { schema: { $ref: '#/components/schemas/AllocationGroupRequest' } } } }
|
||||
responses: { '200': { description: 按客户和业务归属生成的待审核费用行 }, '409': { description: 分摊合计或柜内真实归属不一致 } }
|
||||
/api/platform/v1/loading-plans/{loadingPlanId}/fee-details/allocation-groups/{groupId}/{action}:
|
||||
post:
|
||||
summary: 整组审核、驳回、调整或作废柜级分摊费用
|
||||
description: action 仅为 approve、reject、adjust、void;单行接口拒绝处理分摊组,避免部分成功。
|
||||
security: [{ bearerAuth: [] }]
|
||||
parameters:
|
||||
- { $ref: '#/components/parameters/LoadingPlanId' }
|
||||
- { in: path, name: groupId, required: true, schema: { type: string, pattern: '^[1-9][0-9]{0,19}$' } }
|
||||
- { in: path, name: action, required: true, schema: { type: string, enum: [approve, reject, adjust, void] } }
|
||||
responses: { '200': { description: 整组处理成功 }, '409': { description: 版本、状态或完整性冲突 } }
|
||||
components:
|
||||
parameters:
|
||||
LoadingPlanId: { in: path, name: loadingPlanId, required: true, schema: { type: string, pattern: '^[1-9][0-9]{0,19}$' } }
|
||||
schemas:
|
||||
AllocationGroupRequest:
|
||||
type: object
|
||||
required: [fee, allocations]
|
||||
properties:
|
||||
fee: { type: object, description: 公共费用字段;amount为原始柜级总额 }
|
||||
allocations:
|
||||
type: array
|
||||
minItems: 1
|
||||
maxItems: 200
|
||||
items:
|
||||
type: object
|
||||
required: [customerId, orderId, orderNo, amount]
|
||||
properties:
|
||||
customerId: { type: string }
|
||||
orderId: { type: string }
|
||||
orderNo: { type: string, maxLength: 64 }
|
||||
inboundId: { type: string, nullable: true }
|
||||
inboundCode: { type: string, maxLength: 64, nullable: true }
|
||||
amount: { type: number, format: decimal, exclusiveMinimum: 0 }
|
||||
securitySchemes: { bearerAuth: { type: http, scheme: bearer, bearerFormat: JWT } }
|
||||
Reference in New Issue
Block a user