新增第三方吉林平台接口代码

This commit is contained in:
YAS\29473
2025-06-26 15:41:11 +08:00
parent c0240fdf23
commit ee733ff8e0
9 changed files with 1379 additions and 24 deletions

View File

@@ -46,4 +46,41 @@ public class QueryStartChargeVO {
*/
@JSONField(name = "FailReason")
private int failReason;
// 《*** 吉林平台接口返回参数字段 ***》
/**
* 充电订单号
*/
@JSONField(name = "orderNo")
private String orderNo;
/**
* 充电订单状态
* 1启动中 2充电中 3停止中 4充电完成5订单挂起6充电异常 结束7启动失败
*/
@JSONField(name = "orderStatus")
private Integer orderStatus;
/**
* 充电启动超时时间
*/
@JSONField(name = "overTime")
private Integer overTime;
/**
* 失败码
* 01此设备不存在设备已下线或站 点非正常使用状态时,认为设备不存在); 2此设备离线 3无此设备使用权限 4此设备正忙50~999自定义
*/
@JSONField(name = "FailReasonCode")
private Integer failReasonCode;
/**
* 失败信息
*/
@JSONField(name = "FailReasonMsg")
private String failReasonMsg;
}

View File

@@ -282,20 +282,16 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService {
if (StringUtils.isNotBlank(pileStationInfo.getPictures())) {
stationInfo.setPictures(Lists.newArrayList(pileStationInfo.getPictures().split(",")));
}
List<BillingPriceVO> priceList = pileBillingTemplateService.queryBillingPrice(String.valueOf(pileStationInfo.getId()));
StringBuilder electricityFee = new StringBuilder();
StringBuilder serviceFee = new StringBuilder();
// 查询计费模板
List<BillingPriceVO> priceList = pileBillingTemplateService.queryBillingPrice(String.valueOf(pileStationInfo.getId()));
for (BillingPriceVO billingPriceVO : priceList) {
electricityFee.append(billingPriceVO.getStartTime())
.append("-").append(billingPriceVO.getEndTime())
.append(":").append(billingPriceVO.getElectricityPrice())
.append("");
serviceFee.append(billingPriceVO.getStartTime())
.append("-").append(billingPriceVO.getEndTime())
.append(":").append(billingPriceVO.getServicePrice())
.append("");
String timeRange = billingPriceVO.getStartTime() + "-" + billingPriceVO.getEndTime() + ":";
electricityFee.append(timeRange).append(billingPriceVO.getElectricityPrice()).append("");
serviceFee.append(timeRange).append(billingPriceVO.getServicePrice()).append("");
}
// 去除最后一位的分号
electricityFee.deleteCharAt(electricityFee.length() - 1);
serviceFee.deleteCharAt(serviceFee.length() - 1);
@@ -337,7 +333,7 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService {
*/
@Override
public String notificationStationInfo(String stationId) {
List<SupStationInfo> stationInfos = new ArrayList<>();
List<SupStationInfoDTO> stationInfos = new ArrayList<>();
// 通过id查询站点相关信息
PileStationInfo pileStationInfo = pileStationInfoService.selectPileStationInfoById(Long.parseLong(stationId));
// 查询相关配置信息
@@ -398,19 +394,14 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService {
info.setOfficialRunTime(DateUtils.parseDateToStr(DateUtils.YYYY_MM_DD, pileStationInfo.getCreateTime()));
List<BillingPriceVO> priceList = pileBillingTemplateService.queryBillingPrice(String.valueOf(pileStationInfo.getId()));
StringBuilder electricityFee = new StringBuilder();
StringBuilder serviceFee = new StringBuilder();
// 查询计费模板
List<BillingPriceVO> priceList = pileBillingTemplateService.queryBillingPrice(String.valueOf(pileStationInfo.getId()));
for (BillingPriceVO billingPriceVO : priceList) {
electricityFee.append(billingPriceVO.getStartTime())
.append("-").append(billingPriceVO.getEndTime())
.append(":").append(billingPriceVO.getElectricityPrice())
.append("");
serviceFee.append(billingPriceVO.getStartTime())
.append("-").append(billingPriceVO.getEndTime())
.append(":").append(billingPriceVO.getServicePrice())
.append("");
String timeRange = billingPriceVO.getStartTime() + "-" + billingPriceVO.getEndTime() + ":";
electricityFee.append(timeRange).append(billingPriceVO.getElectricityPrice()).append("");
serviceFee.append(timeRange).append(billingPriceVO.getServicePrice()).append("");
}
// 去除最后一位的分号
electricityFee.deleteCharAt(electricityFee.length() - 1);
@@ -1188,7 +1179,7 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService {
connectorInfo.setVoltageLowerLimits(new BigDecimal(pileDetailInfoVO.getRatedVoltage()).setScale(4, RoundingMode.HALF_UP));
connectorInfo.setCurrent(new BigDecimal(pileDetailInfoVO.getRatedCurrent()).setScale(4, RoundingMode.HALF_UP));
connectorInfo.setPower(new BigDecimal(pileDetailInfoVO.getRatedPower()).setScale(4, RoundingMode.HALF_UP));
connectorInfo.setNationalStandard(StringUtils.equals("1", pileDetailInfoVO.getSpeedType()) ? 12 : 11);
connectorInfo.setNationalStandard(2);
connectorInfo.setAuxPower(3); // 3-兼容12V和24V
connectorInfo.setOperateStatus(50); // 50-正常使用