import request from "@/utils/request";
import constant from "@/utils/constant";

// 分页查询元数据
const getData = (params) => {
    return request.postForm(constant.dtbserverProxy + '/metadata/selectMetadtaDataPage', params);
}
// 通过ID查询元数据
const getDataById = (params) => {
    return request.postForm(constant.dtbserverProxy + '/metadata/selectMetadataDataById', params)
}
// 新增元数据
const addData = (params) => {
    return request.postForm(constant.dtbserverProxy + '/metadata/addMetadataData', params);
}
// 修改元数据
const updateData = (params) => {
    return request.postForm(constant.dtbserverProxy + '/metadata/addMetadataData', params);
}
// 删除元数据
const deleteData = (params) => {
    return request.postForm(constant.dtbserverProxy + '/metadata/deleteMetadataData', params)
}
// 模糊检索其他类型关联数据
const queryRelateData = (params) => {
    return request.postForm(constant.dtbserverProxy + '/metadata/selectMetadataRelevancyData', params)
}

export default {
    getData,
    getDataById,
    addData,
    updateData,
    deleteData,
    queryRelateData,
}