import { api, downloadFile, createApiUrl} from '~/utils/axios';

${excelFun}

${imageFun}

${fileFun}

${dictFun}

/**
 * 获取${functionName}列表
 * @param {Object} data
 * @return {Promise} api
 */
export function get${className}List(data) {
  return api.post('${moduleName}.${className}/get${className}List', data);
}

/**
 * 删除${functionName}
 * @param {Object} data
 * @return {Promise} api
 */
export function delete${className}(data) {
  return api.post('${moduleName}.${className}/delete${className}', data, {
    isTransformResponse: true,
    isShowSuccessMessage: true,
    errorMessageText: '删除失败'
  });
}

/**
 * 添加${functionName}
 * @param {Object} data
 * @return {Promise} api
 */
export function add${className}(data) {
  return api.post('${moduleName}.${className}/add${className}', data, {
    isTransformResponse: true,
    isShowSuccessMessage: true,
    errorMessageText: '添加失败'
  });
}
/**
 * 编辑${functionName}
 * @param {Object} data
 * @return {Promise} api
 */
export function edit${className}(data) {
  return api.post('${moduleName}.${className}/edit${className}', data, {
    isTransformResponse: true,
    isShowSuccessMessage: true,
    errorMessageText: '编辑失败'
  });
}
