feat(admin): consume trucking attachment and history APIs

This commit is contained in:
2026-08-08 15:59:37 +08:00
parent 8771cef76b
commit fc04029850
2 changed files with 21 additions and 3 deletions
+1 -1
View File
@@ -67,7 +67,7 @@ export async function listTruckAppointmentAttachments(id: string | number) {
}
export async function referenceTruckAppointmentAttachment(id: string | number, payload: { fileId: string; attachmentType?: string | null; fileName?: string | null; fileHash?: string | null }) {
const response = await http.post<ApiEnvelope<TruckAttachmentReference>, ApiEnvelope<TruckAttachmentReference>>(`${basePath}/${id}/attachments`, { ...payload, fileId: Number(payload.fileId) })
const response = await http.post<ApiEnvelope<TruckAttachmentReference>, ApiEnvelope<TruckAttachmentReference>>(`${basePath}/${id}/attachments`, payload)
return unwrapApiResponse(response)
}