36 lines
969 B
TypeScript
36 lines
969 B
TypeScript
|
|
import {defHttp} from '/@/utils/http/axios';
|
||
|
|
import { useMessage } from "/@/hooks/web/useMessage";
|
||
|
|
|
||
|
|
const { createConfirm } = useMessage();
|
||
|
|
|
||
|
|
enum Api {
|
||
|
|
list = '/heating/heatanalysis/page',
|
||
|
|
edit='/heating/heatanalysis/updateFaultLevel',
|
||
|
|
companylist = '/heating/thermalcompany/list',
|
||
|
|
heatsourcelist = '/heating/heatsource/list',
|
||
|
|
heatsourcestationlist = '/heating/heatsourcestation/list',
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 列表接口
|
||
|
|
* @param params
|
||
|
|
*/
|
||
|
|
export const list = (params) =>
|
||
|
|
defHttp.get({url: Api.list, params});
|
||
|
|
|
||
|
|
export const companylist = (params) =>
|
||
|
|
defHttp.get({url: Api.companylist, params});
|
||
|
|
|
||
|
|
export const heatsourcelist = (params) =>
|
||
|
|
defHttp.get({url: Api.heatsourcelist, params});
|
||
|
|
|
||
|
|
export const heatsourcestationlist = (params) =>
|
||
|
|
defHttp.get({url: Api.heatsourcestationlist, params});
|
||
|
|
/**
|
||
|
|
* 更新故障等级
|
||
|
|
* @param params
|
||
|
|
*/
|
||
|
|
export const saveOrUpdate = (params) => {
|
||
|
|
return defHttp.post({url: Api.edit, params},{ isTransformResponse: false });
|
||
|
|
}
|