import { httpApi } from '../../request/httpApi'

export default {
    //获取任务类型或任务状态
    async queryTaskTypeStatus(form) {
        return httpApi({
            url: '/api/blade-business/task/query-task-type-status',
            method: 'get',
            params: form,
        })
    },
    //获取当前合同段的上报批次
    async queryBatchList(form) {
        return httpApi({
            url: '/api/blade-business/task/query-batch-list',
            method: 'get',
            params: form,
        })
    },
    //获取当前用户待办流程
    async queryUserToDoTaskList(form) {
        return httpApi({
            url: '/api/blade-business/task/user-to-do-task-list',
            method: 'get',
            params: form,
        })
    },
    //审批页详情
    async queryApprovalParameter(form) {
        return httpApi({
            url: '/api/blade-business/task/query-approval-parameter',
            method: 'get',
            params: form,
        })
    },
    //完成任务
    async saveCompleteApprovalTask(form) {
        return httpApi({
            url: '/api/blade-business/task/complete-approval-task',
            method: 'post',
            data: form,
        })
    },
    //已办任务
    async queryUserDoneTaskList(form) {
        return httpApi({
            url: '/api/blade-business/task/query-user-done-task-list',
            method: 'get',
            params: form,
        })
    },
    //批量审批
    async batchCompleteApprovalTask(form) {
        return httpApi({
            url: '/api/blade-business/task/batch-complete-approval-task',
            method: 'post',
            data: form,
        })
    },
    //获取发起
    async queryUserStartFlow(form) {
        return httpApi({
            url: '/api/blade-business/task/query-user-start-flow',
            method: 'get',
            params: form,
        })
    },
    //批量页详情
    async queryTaskInfo(form) {
        return httpApi({
            url: '/api/blade-business/task/batch-approval-parameter',
            method: 'get',
            params: form,
        })
    },
    //校验电签短信验证码
    async checkSmsCode(form) {
        return httpApi({
            url: '/api/blade-business/task/check-sms-code',
            method: 'post',
            data: form,
        })
    },
    //查询pdf数量
    async queryPDFnum(form) {
        return httpApi({
            url: '/api/blade-business/task/query-approval-parameter-pdf-num',
            method: 'get',
            params: form
        })
    },
}
