import axios from 'axios';
const baseUri = "/sound/function/place";
const listAllUrl = baseUri + "";

// 添加
const savePlace = function (data) {
    return axios.post("/sound/function/place",data)
}
// 批量添加
const savePlaceBatch = function (data) {
    return axios.post("/sound/function/place/batch",data)
}
// 删除
const removePlace = function (id) {
    return axios.delete(`/sound/function/place/${id}`,)
}
// 批量删除
const removeBatchPlace = function (ids) {
    return axios.delete("/sound/function/place/batch",{data:ids})
}

// 修改
const updatePlace = function (data) {
    return axios.put("/sound/function/place",data)
}

const getColumnOptions = function(column){
    return axios.get("/sound/function/place/options",{params:{column}})
}

const copyBatchPlace = function (data){
    return axios.post("/sound/function/place/copyBatch",data)
}

export {
    listAllUrl,
    savePlace,
    updatePlace,
    removeBatchPlace,
    removePlace,
    getColumnOptions,
    copyBatchPlace,
    savePlaceBatch
}
