补齐财务费用原币与尾程录入

This commit is contained in:
2026-09-09 16:37:36 +08:00
parent a869467efb
commit 8f6d4fc03e
8 changed files with 66 additions and 40 deletions
@@ -125,17 +125,14 @@ export interface LastMileStatusHistoryDto {
}
export interface LastMileFeeDto {
id: string
customerId: string
orderId: string
feeItem: string
currency: string
amount: number
status: string
supplierDescription?: string | null
createdBy: string
createdAt: string
updatedAt: string
id: string; sourceFeeId: string; sourceVersion: number; customerId: string; orderId?: string | null
feeItemCode: string; feeItemName: string; direction: 'RECEIVABLE' | 'PAYABLE'
currency: 'CNY'; amount: number; originalCurrency: 'CNY' | 'USD'; originalAmount: number
exchangeRate: number; exchangeRateMonth: string; reviewStatus: 'DRAFT' | 'PENDING' | 'APPROVED' | 'REJECTED'
publicationStatus: string; sourceStatus: string; supplierId?: string | null; supplierName?: string | null
settlementMode?: 'ON_ACCOUNT' | 'DIRECT_PAID' | null; businessDate: string
chargeableQuantity?: number | null; quantityUnit?: string | null; unitPrice?: number | null
periodStart?: string | null; periodEnd?: string | null; createdAt: string; updatedAt: string
}
export interface LastMileOperationDto {
@@ -147,11 +144,11 @@ export interface LastMileOperationDto {
}
export interface CreateLastMileFeePayload {
feeItem: string
currency: string
amount: number
status: string
supplierDescription?: string
feeItemCode: string; feeItemName: string; direction: 'RECEIVABLE' | 'PAYABLE'; currency: 'CNY' | 'USD'
amount: number; businessDate: string; supplierId?: string; supplierName?: string; supplierCategory?: string
settlementMode?: 'ON_ACCOUNT' | 'DIRECT_PAID'; paidAt?: string; paymentMethod?: 'ONLINE' | 'BANK_TRANSFER' | 'CASH' | 'OTHER'
paymentReferenceNo?: string; paymentVoucherFileIds?: string[]; chargeableQuantity?: number
quantityUnit?: string; unitPrice?: number; periodStart?: string; periodEnd?: string
}
export interface TransferDestinationPayload {
@@ -378,6 +375,7 @@ export async function downloadLastMileOrders(query: Partial<LastMileOrderQuery>)
export async function createLastMileOrderFee(orderId: string, payload: CreateLastMileFeePayload) {
const response = await overseasHttp.post<ApiEnvelope<LastMileFeeDto>, ApiEnvelope<LastMileFeeDto>>(
`/platform/v1/last-leg/orders/${encodeURIComponent(orderId)}/fees`, payload,
{ headers: { 'Idempotency-Key': `last-mile-fee-${orderId}-${Date.now()}-${Math.random().toString(36).slice(2)}` } },
)
return unwrapApiResponse(response)
}