1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
| import axios from "./axios";
| import md5 from "js-md5";
| /**
| * 登录系统
| * 参数 "uinf.UName="+用户名+"&uinf.Upassword="+密码+"&uinf.UId="+是否记住密码(0,1)
| * 密码需要使用hex_md5加密
| */
| export const login = (username, password) => {
| return axios({
| method: "post",
| url: `LoginAction_login?uinf.UName=${username}&uinf.Upassword=${md5(password)}&uinf.UId=0`,
| data: null
| })
| }
|
| /**
| * 查询机房信息
| * 参数:json = {"StationName1":"北京市","StationName2":"市辖区","StationName5":"海淀区"}
| */
| export const searchStation = (params) => {
| return axios({
| method: "post",
| url: "BattInfAction!serchAllStationName",
| data: "json=" + JSON.stringify(params)
| })
| }
|
| /**
| * 查询已添加到地图的机房
| * 参数:json={"adata":{"alm_cleared_type":0,"alm_id":1},"bplan":{"discharge_reason":3}}
| */
| export const searchMap = () => {
| return axios({
| method: "post",
| url: "BattMap_informationAction!searchUserManageStation",
| data: "json=" + JSON.stringify({
| adata: {
| alm_cleared_type: 0,
| alm_id: 1,
| },
| bplan: {
| discharge_reason: 3,
| }
| })
| })
| }
|
| export const searchMapHomeState = () => {
| return axios({
| method: "post",
| url: 'BattMap_informationAction!findStationState',
| data: null
| });
| }
|
| /**
| * 首页地图json数据配置 查询关联地图
| * 参数: json={"id":id}
| */
| export const getAllMapOutlineAction = (data) => {
| return axios({
| method: "post",
| url: "MapOutlineAction!getAll",
| data: 'json=' + JSON.stringify(data),
| });
| }
|
|