import request from '@/utils/request'
//新增项目
export function addProject(param) {
  return request({
    url: '/business/info/add',
    method: 'POST',
    data: param
  })
}
//商机列表
export function getProjectlist(param) {
  return request({
    url: '/business/info/list',
    method: 'GET',
    params: param
  })
}
//删除项目
export function delProject(param) {
  return request({
    url: '/business/info/remove/'+param,
    method: 'DELETE',
  })
}
//建设内容
export function getJSNR(param) {
  return request({
    url: '/business/info/construction/'+param,
    method: 'GET',
  })
}
//项目速览
export function getXMSL(param) {
  return request({
    url: '/business/info/browse/'+param,
    method: 'GET',
  })
}
//项目内容修改
export function editXMNR(param) {
  return request({
    url: '/business/info/edit',
    method: 'POST',
    data:param
  })
}
//项目标签新增
export function addLabel(param) {
  return request({
    url: '/business/label/add',
    method: 'POST',
    data:param
  })
}
//项目标签删除
export function removeLabel(param) {
  return request({
    url: '/business/label/remove',
    method: 'POST',
    data:param
  })
}


//查询项目联系人
export function getLXR(param) {
  return request({
    // url: '/business/contacts/list',
    url: '/contact/info/list',
    method: 'GET',
    params:param
  })
}
//修改项目联系人
export function editLXR(param) {
  return request({
    // url: '/business/contacts/edit',
    url: '/contact/info',
    method: 'PUT',
    data:param
  })
}

//新增项目联系人
export function addLXR(param) {
  return request({
    // url: '/business/contacts/add',
    url: '/contact/info',
    method: 'POST',
    data:param
  })
}

//删除项目联系人
export function delLXR(param) {
  return request({
    url: '/contact/info/'+param,
    method: 'DELETE',
  })
}

//跟进记录
export function getGJJL(param) {
  return request({
    url: '/business/record/list',
    method: 'get',
    params:param
  })
}

//新增跟进记录
export function addGJJL(param) {
  return request({
    url: '/business/record/add',
    method: 'POST',
    data:param
  })
}
//删除跟进记录
export function delGJJL(param) {
  return request({
    url: '/business/record/remove/'+param,
    method: 'DELETE',
  })
}


//工作待办
export function getGZDB(param) {
  return request({
    url: '/business/backlog/list',
    method: 'GET',
    params:param
  })
}

//添加工作待办
export function addGZDB(param) {
  return request({
    url: '/business/backlog/add',
    method: 'post',
    data:param
  })
}

//修改工作待办
export function editGZDB(param) {
  return request({
    url: '/business/backlog/edit',
    method: 'post',
    data:param
  })
}
//查询相关企业
export function getXGQY(param) {
  return request({
    url: '/business/company/list',
    method: 'GET',
    params:param
  })
}

//新增相关企业
export function addXGQY(param) {
  return request({
    url: '/business/company/add',
    method: 'POST',
    data:param
  })
}

//编辑相关企业
export function saveXGQY(param) {
  return request({
    url: '/business/company/edit',
    method: 'POST',
    data:param
  })
}

//删除相关企业
export function delXGQY(param) {
  return request({
    url: '/business/company/remove/'+param,
    method: 'DELETE',
  })
}
//查询资料文档
export function getZLWD(param) {
  return request({
    url: '/business/file/list',
    method: 'GET',
    params:param
  })
}

//删除资料文档
export function delZLWD(param) {
  return request({
    url: '/business/file/remove',
    method: 'POST',
    data:param
  })
}

//查询关联项目
export function relateProject(param) {
  return request({
    url: '/business/record/relate/project/'+param,
    method: 'get',
  })
}

//查询跟进动态
export function allRecord(param) {
  return request({
    url: '/business/record/all/list',
    method: 'get',
    params:param,
  })
}

//项目状态统计
export function getStatistics(param) {
  return request({
    url: '/business/overview/status/statistics',
    method: 'get',
    params:param,
  })
}
//储备项目统计
export function getCount(param) {
  return request({
    url: '/business/overview/type/analyze/'+param,
    method: 'get',
    params:param,
  })
}
//储备项目资金
export function getAmount(param) {
  return request({
    url: '/business/overview/amount/analyze',
    method: 'get',
    params:param,
  })
}
//跟进动态
export function getAllRecord(param) {
  return request({
    url: '/business/record/all/list',
    method: 'get',
    params:param,
  })
}
//公招项目地区统计
export function countGroupByProvince(param) {
  return request({
    url: '/business/overview/countGroupByProvince',
    method: 'post',
    data:param
  })
}
//公招项目投资金额统计
export function rangByMoney(param) {
  return request({
    url: '/business/overview/rangByMoney',
    method: 'post',
    data:param
  })
}
