统一财务费用来源入池链路
This commit is contained in:
@@ -194,11 +194,12 @@ paths:
|
||||
/api/platform/v1/last-leg/orders/{id}/fees:
|
||||
post:
|
||||
summary: 新增尾程订单费用
|
||||
description: 权限 platform:overseas-warehouse:last-mile-order:edit;在订单客户范围内新增费用并记录操作人和处理结果。
|
||||
description: 权限 platform:overseas-warehouse:last-mile-order:edit;在订单客户范围内创建统一费用来源并提交财务审核。
|
||||
security: [{ bearerAuth: [] }]
|
||||
parameters:
|
||||
- { name: id, in: path, required: true, schema: { type: integer, format: int64 } }
|
||||
- { name: customerId, in: query, required: false, schema: { type: string, pattern: '^[1-9][0-9]*$' } }
|
||||
- { name: Idempotency-Key, in: header, required: true, schema: { type: string, minLength: 1, maxLength: 128 } }
|
||||
requestBody:
|
||||
required: true
|
||||
content: { application/json: { schema: { $ref: '#/components/schemas/LastMileFeeCreate' } } }
|
||||
@@ -1331,28 +1332,44 @@ components:
|
||||
plannedArrivalAt: { type: string, format: date-time, nullable: true, description: ll_order.estimated_warehouse_at }
|
||||
LastMileFeeCreate:
|
||||
type: object
|
||||
required: [feeItem, currency, amount, status]
|
||||
required: [feeItemCode, feeItemName, direction, currency, amount, businessDate]
|
||||
properties:
|
||||
feeItem: { type: string, minLength: 1, maxLength: 128 }
|
||||
currency: { type: string, pattern: '^[A-Z]{3}$', example: USD }
|
||||
feeItemCode: { type: string, minLength: 1, maxLength: 64 }
|
||||
feeItemName: { type: string, minLength: 1, maxLength: 128 }
|
||||
direction: { type: string, enum: [RECEIVABLE, PAYABLE] }
|
||||
currency: { type: string, enum: [CNY, USD] }
|
||||
amount: { type: number, format: decimal, minimum: 0.01 }
|
||||
status: { type: string, enum: [PENDING_REVIEW, APPROVED, REJECTED] }
|
||||
supplierDescription: { type: string, maxLength: 500 }
|
||||
businessDate: { type: string, format: date }
|
||||
supplierId: { type: string, pattern: '^[1-9][0-9]*$' }
|
||||
supplierName: { type: string, maxLength: 200 }
|
||||
supplierCategory: { type: string, maxLength: 32 }
|
||||
settlementMode: { type: string, enum: [ON_ACCOUNT, DIRECT_PAID] }
|
||||
chargeableQuantity: { type: number, exclusiveMinimum: 0 }
|
||||
quantityUnit: { type: string, maxLength: 32 }
|
||||
unitPrice: { type: number, exclusiveMinimum: 0 }
|
||||
periodStart: { type: string, format: date }
|
||||
periodEnd: { type: string, format: date }
|
||||
LastMileFee:
|
||||
type: object
|
||||
required: [id, customerId, orderId, feeItem, currency, amount, status, createdBy, createdAt, updatedAt]
|
||||
required: [id, sourceFeeId, sourceVersion, customerId, feeItemCode, feeItemName, direction, currency, amount, originalCurrency, originalAmount, reviewStatus, publicationStatus, sourceStatus]
|
||||
properties:
|
||||
id: { type: integer, format: int64 }
|
||||
id: { type: string, pattern: '^[1-9][0-9]*$' }
|
||||
sourceFeeId: { type: string, pattern: '^[1-9][0-9]*$' }
|
||||
sourceVersion: { type: integer, minimum: 1 }
|
||||
customerId: { type: string }
|
||||
orderId: { type: integer, format: int64 }
|
||||
feeItem: { type: string }
|
||||
currency: { type: string }
|
||||
orderId: { type: string, pattern: '^[1-9][0-9]*$' }
|
||||
feeItemCode: { type: string }
|
||||
feeItemName: { type: string }
|
||||
direction: { type: string, enum: [RECEIVABLE, PAYABLE] }
|
||||
currency: { type: string, enum: [CNY] }
|
||||
amount: { type: number, format: decimal }
|
||||
status: { type: string }
|
||||
supplierDescription: { type: string, nullable: true }
|
||||
createdBy: { type: string }
|
||||
createdAt: { type: string, format: date-time }
|
||||
updatedAt: { type: string, format: date-time }
|
||||
originalCurrency: { type: string, enum: [CNY, USD] }
|
||||
originalAmount: { type: number, format: decimal }
|
||||
exchangeRate: { type: number, format: decimal }
|
||||
exchangeRateMonth: { type: string, pattern: '^\\d{4}-\\d{2}$' }
|
||||
reviewStatus: { type: string, enum: [DRAFT, PENDING, APPROVED, REJECTED] }
|
||||
publicationStatus: { type: string }
|
||||
sourceStatus: { type: string }
|
||||
LastMileFeeApiResponse:
|
||||
type: object
|
||||
required: [code, message, data]
|
||||
@@ -1842,11 +1859,22 @@ components:
|
||||
enum: [START_PROCESSING, COMPLETE_EXCEPTION, CANCEL_EXCEPTION]
|
||||
DeliveryFeeInput:
|
||||
type: object
|
||||
required: [feeType, currency, amount]
|
||||
required: [feeType, feeName, direction, currency, amount]
|
||||
properties:
|
||||
feeType: { type: string, maxLength: 64 }
|
||||
currency: { type: string, maxLength: 8 }
|
||||
amount: { type: number, minimum: 0 }
|
||||
feeName: { type: string, maxLength: 128 }
|
||||
direction: { type: string, enum: [RECEIVABLE, PAYABLE] }
|
||||
currency: { type: string, enum: [CNY, USD] }
|
||||
amount: { type: number, exclusiveMinimum: 0 }
|
||||
supplierId: { type: string, pattern: '^[1-9][0-9]*$' }
|
||||
supplierName: { type: string, maxLength: 200 }
|
||||
supplierCategory: { type: string, maxLength: 32 }
|
||||
settlementMode: { type: string, enum: [ON_ACCOUNT, DIRECT_PAID] }
|
||||
chargeableQuantity: { type: number, exclusiveMinimum: 0 }
|
||||
quantityUnit: { type: string, maxLength: 32 }
|
||||
unitPrice: { type: number, exclusiveMinimum: 0 }
|
||||
periodStart: { type: string, format: date }
|
||||
periodEnd: { type: string, format: date }
|
||||
remark: { type: string, nullable: true, maxLength: 500 }
|
||||
OneClickOutboundCreate:
|
||||
type: object
|
||||
|
||||
Reference in New Issue
Block a user