WEB/src/api/order.deliveryOrder/orderdeliveryOrder.ts
2026-06-06 18:16:24 +08:00

68 lines
1.5 KiB
TypeScript

import request from '@/utils/request'
const v = '1.0'
export type { OrderWorkbenchListResponse, OrderListPagination } from '@/api/order.index/orderindex'
export type OrderWhere = Record<string, any>
export type OrderSort = {
sortField?: string
sortOrder?: 'asc' | 'desc' | 'ASC' | 'DESC'
field?: string
order?: 'asc' | 'desc' | 'ASC' | 'DESC'
}
export type OrderPagination = {
page?: number
pageSize?: number
}
export type DeliveryOrderListParams = {
pagination?: OrderPagination
where?: OrderWhere
sort?: OrderSort
}
export type DeliveryOrderDetailParams = {
ids?: Array<number | string> | string | number
id?: number | string
order_id?: number | string
orderId?: number | string
tableType?: string
tablePosition?: string
type?: string
moduleName?: string
}
export function orderDeliveryOrderList(data: DeliveryOrderListParams = {}): Promise<any> {
return request({
url: '/system',
method: 'post',
params: {
method: 'order.deliveryOrder.list',
v,
timestamp: Date.now()
},
data,
isSystemApi: true
} as any)
}
export function orderDeliveryOrderDetail(data: DeliveryOrderDetailParams): Promise<any> {
return request({
url: '/system',
method: 'post',
params: {
method: 'order.deliveryOrder.detail',
v,
timestamp: Date.now()
},
data,
isSystemApi: true
} as any)
}
export const orderDeliveryOrder = {
list: orderDeliveryOrderList,
detail: orderDeliveryOrderDetail
}