import axios from 'axios';
// ----------------------市级字典列表-----------------------
const pageDictUrl = '/drinkingWater/drinkingWaterDict';
const listAllUrl = pageDictUrl + "";

// 添加
const saveDrinkingWaterDict = function (data) {
    return axios.post("/drinkingWater/drinkingWaterDict/",data)
}

// 删除
const removeDrinkingWaterDict = function (id) {
    return axios.delete(`/drinkingWater/drinkingWaterDict/${id}`,)
}
// 批量删除
const removeBatchDrinkingWaterDict = function (ids) {
    return axios.delete("/drinkingWater/drinkingWaterDict/batch",{data:ids})
}

// 修改
const updateDrinkingWaterDict = function (data) {
    return axios.put("/drinkingWater/drinkingWaterDict",data)
}

const getColumnOptions = function(column){
    return axios.get("/drinkingWater/drinkingWaterDict/options",{params:{column}})
}
const copyBatchPlace = function (data){
    return axios.post("/drinkingWater/drinkingWaterDict/copyBatch",data)
}

// ----------------------县级地表水字典列表-----------------------
const pageCountyDictUrl = '/drinkingWater/drinkingWaterCountyDict';
const listCountyAllUrl = pageCountyDictUrl + "";

// 添加
const saveDrinkingWaterCountyDict = function (data) {
    return axios.post("/drinkingWater/drinkingWaterCountyDict/",data)
}

// 删除
const removeDrinkingWaterCountyDict = function (id) {
    return axios.delete(`/drinkingWater/drinkingWaterCountyDict/${id}`,)
}
// 批量删除
const removeBatchDrinkingWaterCountyDict = function (ids) {
    return axios.delete("/drinkingWater/drinkingWaterCountyDict/batch",{data:ids})
}

// 修改
const updateDrinkingWaterCountyDict = function (data) {
    return axios.put("/drinkingWater/drinkingWaterCountyDict",data)
}

const getCountyColumnOptions = function(column){
    return axios.get("/drinkingWater/drinkingWaterCountyDict/options",{params:{column}})
}
const copyBatchCountyPlace = function (data){
    return axios.post("/drinkingWater/drinkingWaterCountyDict/copyBatch",data)
}

// ----------------------县级地下水字典列表-----------------------
const pageCountyBottomDictUrl = '/drinkingWater/drinkingWaterCountyBottomDict';
const listCountyBottomAllUrl = pageCountyBottomDictUrl + "";

// 添加
const saveDrinkingWaterCountyBottomDict = function (data) {
    return axios.post("/drinkingWater/drinkingWaterCountyBottomDict/",data)
}

// 删除
const removeDrinkingWaterCountyBottomDict = function (id) {
    return axios.delete(`/drinkingWater/drinkingWaterCountyBottomDict/${id}`,)
}
// 批量删除
const removeBatchDrinkingWaterCountyBottomDict = function (ids) {
    return axios.delete("/drinkingWater/drinkingWaterCountyBottomDict/batch",{data:ids})
}

// 修改
const updateDrinkingWaterCountyBottomDict = function (data) {
    return axios.put("/drinkingWater/drinkingWaterCountyBottomDict",data)
}

const getCountyBottomColumnOptions = function(column){
    return axios.get("/drinkingWater/drinkingWaterCountyBottomDict/options",{params:{column}})
}
const copyBatchCountyBottomPlace = function (data){
    return axios.post("/drinkingWater/drinkingWaterCountyBottomDict/copyBatch",data)
}

// ----------------------农村地表水字典-----------------------
const pageVillageTopDictUrl = '/drinkingWater/drinkingWaterVillageTopDict';
const listVillageTopAllUrl = pageVillageTopDictUrl + "";

// 添加
const saveDrinkingWaterVillageTopDict = function (data) {
    return axios.post("/drinkingWater/drinkingWaterVillageTopDict/",data)
}

// 删除
const removeDrinkingWaterVillageTopDict = function (id) {
    return axios.delete(`/drinkingWater/drinkingWaterVillageTopDict/${id}`,)
}
// 批量删除
const removeBatchDrinkingWaterVillageTopDict = function (ids) {
    return axios.delete("/drinkingWater/drinkingWaterVillageTopDict/batch",{data:ids})
}

// 修改
const updateDrinkingWaterVillageTopDict = function (data) {
    return axios.put("/drinkingWater/drinkingWaterVillageTopDict",data)
}

const getVillageTopColumnOptions = function(column){
    return axios.get("/drinkingWater/drinkingWaterVillageTopDict/options",{params:{column}})
}
const copyBatchVillageTopPlace = function (data){
    return axios.post("/drinkingWater/drinkingWaterVillageTopDict/copyBatch",data)
}

// ----------------------农村地下水字典-----------------------
const pageVillageBottomDictUrl = '/drinkingWater/drinkingWaterVillageBottomDict';
const listVillageBottomAllUrl = pageVillageBottomDictUrl + "";

// 添加
const saveDrinkingWaterVillageBottomDict = function (data) {
    return axios.post("/drinkingWater/drinkingWaterVillageBottomDict/",data)
}

// 删除
const removeDrinkingWaterVillageBottomDict = function (id) {
    return axios.delete(`/drinkingWater/drinkingWaterVillageBottomDict/${id}`,)
}
// 批量删除
const removeBatchDrinkingWaterVillageBottomDict = function (ids) {
    return axios.delete("/drinkingWater/drinkingWaterVillageBottomDict/batch",{data:ids})
}

// 修改
const updateDrinkingWaterVillageBottomDict = function (data) {
    return axios.put("/drinkingWater/drinkingWaterVillageBottomDict",data)
}

const getVillageBottomColumnOptions = function(column){
    return axios.get("/drinkingWater/drinkingWaterVillageBottomDict/options",{params:{column}})
}
const copyBatchVillageBottomPlace = function (data){
    return axios.post("/drinkingWater/drinkingWaterVillageBottomDict/copyBatch",data)
}


export {
    //市级
    pageDictUrl,
    listAllUrl,
    saveDrinkingWaterDict,
    removeDrinkingWaterDict,
    removeBatchDrinkingWaterDict,
    updateDrinkingWaterDict,
    getColumnOptions,
    copyBatchPlace,
    // 县级地表水
    pageCountyDictUrl,
    listCountyAllUrl,
    saveDrinkingWaterCountyDict,
    removeDrinkingWaterCountyDict,
    removeBatchDrinkingWaterCountyDict,
    updateDrinkingWaterCountyDict,
    getCountyColumnOptions,
    copyBatchCountyPlace,
    //县级地下水
    pageCountyBottomDictUrl,
    listCountyBottomAllUrl,
    saveDrinkingWaterCountyBottomDict,
    removeDrinkingWaterCountyBottomDict,
    removeBatchDrinkingWaterCountyBottomDict,
    updateDrinkingWaterCountyBottomDict,
    getCountyBottomColumnOptions,
    copyBatchCountyBottomPlace,
    //农村地表水
    pageVillageTopDictUrl,
    listVillageTopAllUrl,
    saveDrinkingWaterVillageTopDict,
    removeDrinkingWaterVillageTopDict,
    removeBatchDrinkingWaterVillageTopDict,
    updateDrinkingWaterVillageTopDict,
    getVillageTopColumnOptions,
    copyBatchVillageTopPlace,
    //农村地下水
    pageVillageBottomDictUrl,
    listVillageBottomAllUrl,
    saveDrinkingWaterVillageBottomDict,
    removeDrinkingWaterVillageBottomDict,
    removeBatchDrinkingWaterVillageBottomDict,
    updateDrinkingWaterVillageBottomDict,
    getVillageBottomColumnOptions,
    copyBatchVillageBottomPlace,
}