import request from '@/utils/request'

import { business} from '@/api/index'
//respScoreInput
/**
 *
 * @param {*上传数据obj} data
 * @param {*分页参数} page
 */
export function respScoreInputFindByPage(data, page) {
    return request({
        url: `${business}respScoreInput/findByPage/${page.page}/${page.size}`,
        method: 'post',
        data: data
    })
}
/**
 *
 * @param {查询接口} id
 */


export function respScoreInputFindById(id) {
    return request({
        url: `${business}respScoreInput/findById/${id}`,
        method: 'get',
    })
}


/**
 *
 * @param {保存} id
 */

export function respScoreInputUpdateZCity(data) {
    return request({
        url: `${business}respScoreInput/updateZCity`,
        method: 'post',
        data: data
    })
}

/**
 *
 * @param {传入年份} year
 */

export function respScoreInputUpdateCitySubmit(year) {
    return request({
        url: `${business}respScoreInput/updateCitySubmit/${year}`,
        method: 'get',
    })
}


/**
 *  粮食安全行政盟市长责任制--盟市评分结果录入---导入评分表
 * @param {上传文件} file
 */

export function respScoreInputDownloadCityExcel(formData) {
  return request({
    url: `${business}examinationExcel/downloadCityExcel`,
    method: 'post',
    data:formData
  })
}


/**
 *  盟市、外部单位牵头部门、配合部门评分--查询是否可以提交数据
 * @param {上传文件} file
 */

export function respScoreInputFindByIsSubmit(year,source) {
  return request({
    url: `${business}respScoreInput/findByIsSubmit/${source}/${year}`,
    method: 'get'
  })
}



/**
 *  盟市考核进度明细列表查询选项
 * @param {上传文件} file
 */

export function findBySelect(year,billityId) {
  return request({
    url: `${business}respSummary/findBySelect/${year}/${billityId}`,
    method: 'get'
  })
}




/**
 *考核部门汇总表---查询各盟市考核目标任务列表
 * @param {*分页参数} page
 */
export function findCityByPage(data, page) {
  return request({
    url: `${business}respSummary/findCityByPage/${page.page}/${page.size}`,
    method: 'post',
    data: data
  })
}


/**
 *  粮食安全行政盟市长责任制---根据id查询牵头部门--明细
 * @param {上传文件} file
 */

export function findByQtbmInfo(id,type) {
  return request({
    url: `${business}respScoreInput/findByQtbmInfo/${id}/${type}`,
  method: 'get'
})
}



