// @ts-ignore
/* eslint-disable */

// 该文件自动生成，请勿手动修改！

// --------------------------------------------------------------------------
// 高中模拟划线计划管理服务
// --------------------------------------------------------------------------

import { request } from '@umijs/max';

/** 添加计划 POST /api/ncee/plan/add */
export async function add(data: API.AddNceePlanInput, options?: { [key: string]: any }) {
    const url = '/api/ncee/plan/add';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<any>>(url, config);
    return res?.data;
}

/** 更新计划 POST /api/ncee/plan/update */
export async function update(data: API.UpdateNceePlanInput, options?: { [key: string]: any }) {
    const url = '/api/ncee/plan/update';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<any>>(url, config);
    return res?.data;
}

/** 删除计划 POST /api/ncee/plan/del */
export async function del(data: API.BaseId, options?: { [key: string]: any }) {
    const url = '/api/ncee/plan/del';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<any>>(url, config);
    return res?.data;
}

/** 开始监测 POST /api/ncee/plan/start */
export async function start(data: API.BaseId, options?: { [key: string]: any }) {
    const url = '/api/ncee/plan/start';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<any>>(url, config);
    return res?.data;
}

/** 结束监测 POST /api/ncee/plan/stop */
export async function stop(data: API.BaseId, options?: { [key: string]: any }) {
    const url = '/api/ncee/plan/stop';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<any>>(url, config);
    return res?.data;
}

/** 取消监测 POST /api/ncee/plan/cancel */
export async function cancel(data: API.BaseId, options?: { [key: string]: any }) {
    const url = '/api/ncee/plan/cancel';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<any>>(url, config);
    return res?.data;
}

/** 根据ID获取计划 GET /api/ncee/plan/get-by-id */
export async function getById(
    params: {
        /**  */
        id?: number;
    },
    options?: { [key: string]: any },
) {
    const url = '/api/ncee/plan/get-by-id';
    const config = { method: 'GET', params, ...(options || {}) };
    const res = await request<API.ResponseType<API.NceePlanOutput>>(url, config);
    return res?.data;
}

/** 分页查询计划列表 POST /api/ncee/plan/query-page-list */
export async function queryPageList(data: API.NceePlanPageInput, options?: { [key: string]: any }) {
    const url = '/api/ncee/plan/query-page-list';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<API.PageResponse<API.NceePlanOutput>>>(url, config);
    return res?.data;
}

/** 获取我的单据状态数量 POST /api/ncee/plan/query-status-count */
export async function queryStatusCount(
    data: API.NceePlanPageInput,
    options?: { [key: string]: any },
) {
    const url = '/api/ncee/plan/query-status-count';
    const config = { method: 'POST', data, ...(options || {}) };
    const res = await request<API.ResponseType<API.StatusCount[]>>(url, config);
    return res?.data;
}

export default {
    /** 添加计划 POST /api/ncee/plan/add */
    add,
    /** 更新计划 POST /api/ncee/plan/update */
    update,
    /** 删除计划 POST /api/ncee/plan/del */
    del,
    /** 开始监测 POST /api/ncee/plan/start */
    start,
    /** 结束监测 POST /api/ncee/plan/stop */
    stop,
    /** 取消监测 POST /api/ncee/plan/cancel */
    cancel,
    /** 根据ID获取计划 GET /api/ncee/plan/get-by-id */
    getById,
    /** 分页查询计划列表 POST /api/ncee/plan/query-page-list */
    queryPageList,
    /** 获取我的单据状态数量 POST /api/ncee/plan/query-status-count */
    queryStatusCount,
};
