import request from '@/utils/request'

const projectplan =(data)=>{
  return request({
      url:`projectplan/listByPage?pagenum=${data.pagenum}&pagesize=${data.pagesize}`,
      method:"get"
  })
}
const addProjectplan =(pairs)=>{
  return request({
      url:`projectplan/add-modify-projectplan`,
      method:"post",
      data: pairs
  })
}
const removeProjectplan =(data)=>{
  return request({
      url:`/projectplan/remove-projectplans/${data.id}`,
      method:"delete",
  })
}
const wtls=(data)=>{
  return request({
      url:`/back/wtls`,
      method:"get"
  })
}

const indicators =(data)=>{
  return request({
      url:`indicators/List?stationid=${data.windpowerstationid}&stationname=${data.name}&pageNum=${data.pagenum}&pageSize=${data.pagesize}`,
      method:"get"
  })
}
const addIndicators =(pairs)=>{
  return request({
      url:`indicators/add`,
      method:"post",
      data: pairs
  })
}
const removeIndicators =(data)=>{
  return request({
      url:`/indicators/${data.id}`,
      method:"delete",
  })
}
export default {
  projectplan,
  addProjectplan,
  removeProjectplan,
  wtls,
  indicators,
  addIndicators,
  removeIndicators,
};
