import { get, put, putJ, postJ, deleteApi } from "@/utils/request"; import Vue from "vue"; /** * 获取信息列表 */ export async function getTableList(params) { const res = await get(Vue.prototype.apiUrl + `/eom/purchaserequirement/page`, params); if (res.code == 0) { return res.data; } return Promise.reject(new Error(res.message)); } /** * 获取信息详情 */ export async function getDetail(id) { const res = await get(Vue.prototype.apiUrl + `/eom/purchaserequirement/getById/${id}`, {}); if (res.code == 0) { return res.data; } return Promise.reject(new Error(res.message)); } /** * 删除事项 */ export async function deleteInformation(data) { const res = await deleteApi(Vue.prototype.apiUrl + '/eom/purchaserequirement/delete', data); if (res.code == 0) { return res.data; } return Promise.reject(new Error(res.message)); }