import request from '@/utils/request'

// 查询在线申报记录列表
export function getTemplateInfo(query) {
  return request({
    url: `/system/templateInfo/${query.templateId}`,
    method: 'get',
    params: query
  })
}

// 获取公司信息
export function getBasicInfo(query) {
  return request({
    url: `/system/enterpriseBasicInfo/${query.enterpriseId}`,
    method: 'get',
    params: query
  })
}

// 获取公司信息
export function getOpenInterface(query) {
  return request({
    url: `/system/openInterface/${query.templateRecordId}`,
    method: 'get',
  })
}

// 通过统一社会代码获取对应公司模版
export function getEnterpriseInfo(query) {
  return request({
    url: `/system/openInterface/enterpriseInfo/${query.socialCode}`,
    method: 'get',
    params: query
  })
}

/* 统一补录上传数据 */
export function unifyReport(data) {
  return request({
    url: '/system/openInterface',
    method: 'post',
    data: data,
  })
}

// 获取全部模版编辑信息
export function getDeclarationRecords(query) {
  return request({
    url: `/system/declarationRecords/${query.id}`,
    method: 'get',
    params: query
  })
}


// 查询申报模版列表
export function templateList(query) {
  return request({
    url: '/system/templateRecord/templateNameList',
    method: 'get',
    params: query
  })
}

// 导出
export function exportData(data) {
  return request({
    url: '/system/declarationRecords/export',
    method: 'post',
    responseType: 'blob',
    data: data
  })
}

// 上传单个文件
export function uploadFile(data) {
  return request({
    url: "/common/upload",
    method: 'post',
    data: data,
    headers: {
      'Content-type': 'multipart/form-data'
    }
  })
}


// 新增-项目落户奖补-1
export function addProjectSettlementAward(data) {
  return request({
    url: '/system/projectSettlementAward',
    method: 'post',
    data: data
  })
}

// 编辑-项目落户奖补-1
export function putProjectSettlementAward(data) {
  return request({
    url: '/system/projectSettlementAward',
    method: 'put',
    data: data
  })
}

// 新增-做大做强奖补-2-完成
export function addBigStrongAward(data) {
  return request({
    url: '/system/bigStrongAward',
    method: 'post',
    data: data
  })
}

// 编辑-做大做强奖补-2
export function putBigStrongAward(data) {
  return request({
    url: '/system/bigStrongAward',
    method: 'put',
    data: data
  })
}

// 新增-载体建设奖补-3
export function addCarrierConstructionAward(data) {
  return request({
    url: '/system/carrierConstructionAward',
    method: 'post',
    data: data
  })
}

// 编辑-载体建设奖补-3
export function putCarrierConstructionAward(data) {
  return request({
    url: '/system/carrierConstructionAward',
    method: 'put',
    data: data
  })
}

// 新增-平台建设奖补-4-完成
export function addPlatformConstructionAward(data) {
  return request({
    url: '/system/platformConstructionAward',
    method: 'post',
    data: data
  })
}

// 编辑-平台建设奖补-4
export function putPlatformConstructionAward(data) {
  return request({
    url: '/system/platformConstructionAward',
    method: 'put',
    data: data
  })
}

// 新增-品牌打造奖补-5
export function addBrandingAward(data) {
  return request({
    url: '/system/brandingAward',
    method: 'post',
    data: data
  })
}

// 编辑-品牌打造奖补-5
export function putBrandingAward(data) {
  return request({
    url: '/system/brandingAward',
    method: 'put',
    data: data
  })
}

// 新增-场景开放奖补-6-完成
export function addSceneOpeningAward(data) {
  return request({
    url: '/system/sceneOpeningAward',
    method: 'post',
    data: data
  })
}

// 编辑-场景开放奖补-6
export function putSceneOpeningAward(data) {
  return request({
    url: '/system/sceneOpeningAward',
    method: 'put',
    data: data
  })
}

// 新增-信用管理奖补-7
export function addCreditManagement(data) {
  return request({
    url: '/system/creditManagement',
    method: 'post',
    data: data
  })
}

// 编辑-信用管理奖补-7
export function putCreditManagement(data) {
  return request({
    url: '/system/creditManagement',
    method: 'put',
    data: data
  })
}

// 新增-5G+工业互联网奖补-8
export function addIndustrialInternetAward(data) {
  return request({
    url: '/system/industrialInternetAward',
    method: 'post',
    data: data
  })
}

// 编辑-5G+工业互联网奖补-8
export function putIndustrialInternetAward(data) {
  return request({
    url: '/system/industrialInternetAward',
    method: 'put',
    data: data
  })
}

// 新增-制造服务业有效投入奖补-9
export function addManufacturingServicesAward(data) {
  return request({
    url: '/system/manufacturingServicesAward',
    method: 'post',
    data: data
  })
}

// 编辑-制造服务业有效投入奖补-9
export function putManufacturingServicesAward(data) {
  return request({
    url: '/system/manufacturingServicesAward',
    method: 'put',
    data: data
  })
}

// 新增-物流发展奖补-10
export function addLogisticsDevelopmentAward(data) {
  return request({
    url: '/system/logisticsDevelopmentAward',
    method: 'post',
    data: data
  })
}

// 编辑-物流发展奖补-10
export function putLogisticsDevelopmentAward(data) {
  return request({
    url: '/system/logisticsDevelopmentAward',
    method: 'put',
    data: data
  })
}

// 新增-两业融合奖补-11
export function addIntegrationIndustries(data) {
  return request({
    url: '/system/integrationIndustries',
    method: 'post',
    data: data
  })
}

// 编辑-两业融合奖补-11
export function putIntegrationIndustries(data) {
  return request({
    url: '/system/integrationIndustries',
    method: 'put',
    data: data
  })
}

