// 电子标签任务接口
import type {IEtagTaskQuery} from "@/interface/page/etagTask/IEtagTaskQuery.ts";
import axiosInstance from "@/api/axios.ts";
import type {IAppEtagTask} from "@/model/table/IAppEtagTask.ts";

export default class EtagTaskApi {

    // 查询电子标签任务接口
    static queryEtagTask(params: IEtagTaskQuery, pageIndex: number, pageSize: number) {
        return axiosInstance.post('/app/etagTask/queryEtagTask', params, {
            params: {
                pageIndex: pageIndex,
                pageSize: pageSize
            }
        })
    };

    // 添加电子标签任务
    static addEtagTask(params: IAppEtagTask) {
        return axiosInstance.post('/app/etagTask/addEtagTask', params)
    };

    // 修改电子标签任务
    static editEtagTask(params: IAppEtagTask) {
        return axiosInstance.post('/app/etagTask/updateEtagTask', params)
    };


    // 查询电子标签任务接口 ---- 备份表
    static queryEtagTaskBak(params: IEtagTaskQuery, pageIndex: number, pageSize: number) {
        return axiosInstance.post('/app/etagTask/queryEtagTaskBak', params, {
            params: {
                pageIndex: pageIndex,
                pageSize: pageSize
            }
        })
    };
}