import request from '@/utils/httpRequest'

export default class ProgramProjectListInfoService {
  list (params) {
    return request({
      url: '/program/projectList/list',
      method: 'get',
      params: params
    })
  }
  list2 (params) {
    return request({
      url: '/program/projectList/list2',
      method: 'get',
      params: params
    })
  }
  list2022 (params) {
    return request({
      url: '/program/projectList/list2022',
      method: 'get',
      params: params
    })
  }
  exportFile (params) {
    return request({
      url: '/program/projectList/exportFile',
      method: 'get',
      params: params,
      responseType: 'blob'
    })
  }
  queryById (id) {
    return request({
      url: '/program/projectList/findById',
      method: 'get',
      params: {id: id}
    })
  }
  findByIdAudit (id) {
    return request({
      url: '/program/projectList/findByIdAudit',
      method: 'get',
      params: {id: id}
    })
  }
  findByIdArchive (id) {
    return request({
      url: '/program/projectList/findByIdArchive',
      method: 'get',
      params: {id: id}
    })
  }
  save (inputForm) {
    return request({
      url: `/program/projectList/save`,
      method: 'post',
      data: inputForm
    })
  }
  save2022 (inputForm) {
    return request({
      url: `/program/projectList/save2022`,
      method: 'post',
      data: inputForm
    })
  }
  saveForm (inputForm) {
    return request({
      url: `/program/projectList/saveForm`,
      method: 'post',
      data: inputForm
    })
  }
  saveFormThree (inputForm) {
    return request({
      url: `/program/projectList/saveFormThree`,
      method: 'post',
      data: inputForm
    })
  }
  saveFormArchive (inputForm) {
    return request({
      url: `/program/projectList/saveFormArchive`,
      method: 'post',
      data: inputForm
    })
  }
  delete (ids) {
    return request({
      url: '/program/projectList/deleteById',
      method: 'get',
      params: {id: ids}
    })
  }
  deleteAll (ids) {
    return request({
      url: '/program/projectList/delete',
      method: 'delete',
      params: {ids: ids}
    })
  }
  findContractPageList (params) {
    return request({
      url: '/program/projectList/findContractPageList',
      method: 'get',
      params: params
    })
  }
  updateStatusById (data) {
    return request({
      url: '/program/projectList/updateStatusById',
      method: 'post',
      data: data
    })
  }
  updateStatusByAuditId (data) {
    return request({
      url: '/program/projectList/updateStatusByAuditId',
      method: 'post',
      data: data
    })
  }
  updateStatusByArchiveId (data) {
    return request({
      url: '/program/projectList/updateStatusByArchiveId',
      method: 'post',
      data: data
    })
  }
  saveReportNo (id) {
    return request({
      url: '/program/projectList/saveReportNo',
      method: 'get',
      params: {id: id}
    })
  }
  /* 一级校审文档下载 */
  downloadFirstAuditTpl (id, auditId1) {
    return request({
      url: '/program/projectList/downloadFirstAuditTpl',
      method: 'get',
      params: {id: id, auditId1: auditId1},
      responseType: 'blob'
    })
  }
  /* 二级校审文档下载 */
  downloadSecondAuditTpl (id, auditId2) {
    return request({
      url: '/program/projectList/downloadSecondAuditTpl',
      method: 'get',
      params: {id: id, auditId2: auditId2},
      responseType: 'blob'
    })
  }
  /* 三级校审文档下载 */
  downloadThirdlyAuditTpl (id, auditId3) {
    return request({
      url: '/program/projectList/downloadThirdlyAuditTpl',
      method: 'get',
      params: {id: id, auditId3: auditId3},
      responseType: 'blob'
    })
  }
  /* 三级校审文档下载 */
  downloadProofreadAuditTpl (id) {
    return request({
      url: '/program/projectList/downloadProofreadAuditTpl',
      method: 'get',
      params: {id: id},
      responseType: 'blob'
    })
  }
  /* 三级校审文档下载 */
  downloadAuditRecordFormAfterBindingTpl (id) {
    return request({
      url: '/program/projectList/downloadAuditRecordFormAfterBindingTpl',
      method: 'get',
      params: {id: id},
      responseType: 'blob'
    })
  }
  /* 三级校审文档下载 */
  downloadReportAusstellungTpl (id) {
    return request({
      url: '/program/projectList/downloadReportAusstellungTpl',
      method: 'get',
      params: {id: id},
      responseType: 'blob'
    })
  }
  getHaveProjectIds () {
    return request({
      url: '/program/projectList/getHaveProjectIds',
      method: 'get'
    })
  }
}
