import { get, put, post, del, uploadFile } from '@/utils/request'; import { downloadFile } from '@/utils'; /** * 获得列表数据 * * @param {*} data */ export const getList = data => get('/api/v1/params/operations', data); /** * 添加 * @param {*} data */ export const add = data => post('/api/v1/params/operations', data); /** * 更新 * @param {*} data */ export const update = data => put('/api/v1/params/operations', data); /** * 删除 * @param {*} data */ export const remove = data => del(`/api/v1/params/operations/${data.paramId}`, data); /** * 导出 * @param {*} params */ export const exportParam = params => downloadFile('/api/v1/params/operationparameter_export_excel', params); /** * 参数导入 * @param {*} param0 */ export const uploadParams = ({ file, onSuccess }) => uploadFile({ action: '/api/v1/params/opp_import', file, onSuccess, });