2023-03-04 16:29:55 +08:00
|
|
|
import request from "@/utils/request";
|
|
|
|
|
import {parseTime} from "@/utils/common";
|
|
|
|
|
|
|
|
|
|
// 查询充电站信息列表
|
|
|
|
|
export function listStation(query) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/list",
|
|
|
|
|
method: "get",
|
|
|
|
|
params: query,
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 查询充电站信息详细
|
|
|
|
|
export function getStation(id) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/" + id,
|
|
|
|
|
method: "get",
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 查询充电站信息详细
|
|
|
|
|
export function getStationInfo(stationId) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/getStationInfo/" + stationId,
|
|
|
|
|
method: "get",
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 根据运营商id 查询充电站列表
|
|
|
|
|
export function getStationListByMerchantId(merchantId) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/selectStationListByMerchantId",
|
|
|
|
|
method: "post",
|
|
|
|
|
data: {
|
|
|
|
|
merchantId: merchantId,
|
|
|
|
|
},
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 新增充电站信息
|
|
|
|
|
export function addStation(data) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station",
|
|
|
|
|
method: "post",
|
|
|
|
|
data: data,
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 修改充电站信息
|
|
|
|
|
export function updateStation(data) {
|
|
|
|
|
console.log("修改充电站信息data", data)
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station",
|
|
|
|
|
method: "put",
|
|
|
|
|
data: data,
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 删除充电站信息
|
|
|
|
|
export function delStation(id) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/" + id,
|
|
|
|
|
method: "delete",
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 快速建站接口
|
|
|
|
|
export function fastCreateStation(data) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/fastCreateStation",
|
|
|
|
|
method: "post",
|
|
|
|
|
data: data,
|
|
|
|
|
});
|
|
|
|
|
}
|
2023-03-31 16:19:26 +08:00
|
|
|
|
|
|
|
|
// 下发二维码
|
|
|
|
|
export function updateStationQRCodePrefix(data) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/updateStationQRCodePrefix",
|
|
|
|
|
method: "post",
|
|
|
|
|
data: data,
|
|
|
|
|
});
|
|
|
|
|
}
|
2023-05-25 15:24:48 +08:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 查询站点互联互通配置
|
|
|
|
|
* @param id
|
|
|
|
|
* @returns {AxiosPromise}
|
|
|
|
|
*/
|
|
|
|
|
export function getSettingByStationId(id) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/getSettingByStationId/" + id,
|
|
|
|
|
method: "get",
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
2023-06-05 16:43:26 +08:00
|
|
|
// 查询站点互联互通配置
|
|
|
|
|
export function getSettingInfo(data) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/getSettingInfo",
|
|
|
|
|
method: "post",
|
|
|
|
|
data: data,
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
2023-05-25 15:24:48 +08:00
|
|
|
// 修改站点互联互通配置
|
|
|
|
|
export function updateSettingByStationId(data) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/updateSettingByStationId",
|
|
|
|
|
method: "post",
|
|
|
|
|
data: data,
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// export function insertSettingInfo(data) {
|
|
|
|
|
// return request({
|
|
|
|
|
// url: "/pile/station/insertSettingInfo",
|
|
|
|
|
// method: "post",
|
|
|
|
|
// data: data,
|
|
|
|
|
// })
|
|
|
|
|
// }
|
2023-05-26 08:58:42 +08:00
|
|
|
|
|
|
|
|
export function pushStationInfo(data) {
|
|
|
|
|
return request({
|
|
|
|
|
url: "/pile/station/pushStationInfo",
|
|
|
|
|
method: "post",
|
|
|
|
|
data: data,
|
|
|
|
|
})
|
|
|
|
|
}
|