This commit is contained in:
2026-08-18 17:40:40 +08:00
parent 6ff77e92b2
commit c188482c24
18 changed files with 423 additions and 97 deletions
@@ -38,6 +38,12 @@ export interface ContainerFeeSaveRequest {
remark: string | null
}
export interface ContainerFeeAdjustRequest {
expectedSourceVersion: number
businessDate: string
amount: number
}
export interface ApplicableFeeItem {
id: string
name: string
@@ -109,8 +115,8 @@ export async function rejectContainerFee(planId: string, accountId: string, feeI
await http.post(`${base(planId)}/${encodeURIComponent(feeId)}/reject`, { reason }, { params: params(accountId) })
}
export async function adjustContainerFee(planId: string, accountId: string, feeId: string, expectedSourceVersion: number, values: ContainerFeeSaveRequest) {
const response = await http.post<ApiEnvelope<Record<string, unknown>>, ApiEnvelope<Record<string, unknown>>>(`${base(planId)}/${encodeURIComponent(feeId)}/adjust`, { expectedSourceVersion, ...values }, { params: params(accountId) })
export async function adjustContainerFee(planId: string, accountId: string, feeId: string, payload: ContainerFeeAdjustRequest) {
const response = await http.post<ApiEnvelope<Record<string, unknown>>, ApiEnvelope<Record<string, unknown>>>(`${base(planId)}/${encodeURIComponent(feeId)}/adjust`, payload, { params: params(accountId) })
return normalizeFee(unwrapApiResponse(response))
}