46 lines
1.2 KiB
TypeScript
46 lines
1.2 KiB
TypeScript
import type { PageParam, PageResult } from '@/http/types'
|
|
import { http } from '@/http/http'
|
|
|
|
export interface AgriTraceSnapshotVO {
|
|
id: number
|
|
traceCode: string
|
|
batchId: number
|
|
batchNo: string
|
|
productName?: string
|
|
plotName?: string
|
|
harvestTime?: string
|
|
harvestOperatorId?: number
|
|
harvestOperatorName?: string
|
|
packingTime?: string
|
|
packingOperatorId?: number
|
|
packingOperatorName?: string
|
|
warehouseTime?: string
|
|
warehouseOperatorId?: number
|
|
warehouseOperatorName?: string
|
|
shipmentTime?: string
|
|
shipmentOperatorId?: number
|
|
shipmentOperatorName?: string
|
|
vehicleNo?: string
|
|
invoiceStatus?: string
|
|
snapshotJson?: string
|
|
}
|
|
|
|
export interface AgriTraceSnapshotPageReqVO extends PageParam {
|
|
batchId?: number
|
|
batchNo?: string
|
|
traceCode?: string
|
|
productName?: string
|
|
}
|
|
|
|
export function getAgriTraceSnapshotPage(params: AgriTraceSnapshotPageReqVO) {
|
|
return http.get<PageResult<AgriTraceSnapshotVO>>('/agri/trace/snapshot/page', params)
|
|
}
|
|
|
|
export function getAgriTraceSnapshot(id: number) {
|
|
return http.get<AgriTraceSnapshotVO>(`/agri/trace/snapshot/get?id=${id}`)
|
|
}
|
|
|
|
export function getAgriTraceSnapshotByTraceCode(traceCode: string) {
|
|
return http.get<AgriTraceSnapshotVO>('/agri/trace/snapshot/get-by-trace-code', { traceCode })
|
|
}
|