35 lines
780 B
TypeScript
35 lines
780 B
TypeScript
import type { PageRecord } from "@/lib/api"
|
|
import type { Batch } from "@/models/batch"
|
|
import { callByUser } from "./base"
|
|
|
|
export async function getPageBatch(params: {
|
|
page: number
|
|
size: number
|
|
user_phone?: string
|
|
resource_no?: string
|
|
batch_no?: string
|
|
prov?: string
|
|
city?: string
|
|
isp?: string
|
|
created_at_start?: Date
|
|
created_at_end?: Date
|
|
}) {
|
|
return callByUser<PageRecord<Batch>>("/api/admin/batch/page", params)
|
|
}
|
|
|
|
export async function getBatch(params: {
|
|
page: number
|
|
size: number
|
|
user_id: number
|
|
user_phone?: string
|
|
resource_no?: string
|
|
batch_no?: string
|
|
prov?: string
|
|
city?: string
|
|
isp?: string
|
|
created_at_start?: Date
|
|
created_at_end?: Date
|
|
}) {
|
|
return callByUser<PageRecord<Batch>>("/api/admin/batch/page/of-user", params)
|
|
}
|