mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-22 03:55:17 +08:00
对接浙江平台
This commit is contained in:
@@ -5,9 +5,9 @@ import com.alibaba.fastjson2.annotation.JSONField;
|
||||
import com.jsowell.pile.thirdparty.EquipmentInfo;
|
||||
import com.jsowell.pile.thirdparty.publicinfo.BaseStationInfo;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
@@ -18,7 +18,7 @@ import java.util.List;
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Builder
|
||||
@SuperBuilder
|
||||
public class StationInfo extends BaseStationInfo {
|
||||
/**
|
||||
* 充电站ID Y
|
||||
@@ -123,7 +123,7 @@ public class StationInfo extends BaseStationInfo {
|
||||
* 可停放进行充电的车位总数(默认:0-未知)
|
||||
*/
|
||||
@JSONField(name = "ParkNums")
|
||||
private int parkNums;
|
||||
private Integer parkNums = 0;
|
||||
|
||||
/**
|
||||
* 经度 Y
|
||||
@@ -239,7 +239,7 @@ public class StationInfo extends BaseStationInfo {
|
||||
* 充电设备是否需要提前预约后才能使用。(0-不支持预约;1-支持预约) 不填默认为0
|
||||
*/
|
||||
@JSONField(name = "SupportOrder")
|
||||
private int supportOrder;
|
||||
private Integer supportOrder = 0;
|
||||
|
||||
/**
|
||||
* 备注 N
|
||||
|
||||
@@ -2,12 +2,18 @@ package com.jsowell.thirdparty.platform.domain;
|
||||
|
||||
import com.alibaba.fastjson2.annotation.JSONField;
|
||||
import com.jsowell.thirdparty.platform.common.StationInfo;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
|
||||
/**
|
||||
* 内蒙古平台站点信息
|
||||
*/
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@SuperBuilder
|
||||
public class SupStationInfo extends StationInfo {
|
||||
/**
|
||||
* 充换电站唯一编码
|
||||
|
||||
@@ -4,7 +4,6 @@ import cn.hutool.http.HttpUtil;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.google.common.collect.Maps;
|
||||
import com.jsowell.common.core.domain.ykc.RealTimeMonitorData;
|
||||
import com.jsowell.common.util.DateUtils;
|
||||
import com.jsowell.common.util.JWTUtils;
|
||||
import com.jsowell.common.util.StringUtils;
|
||||
@@ -518,5 +517,4 @@ public interface ThirdPartyPlatformService extends InitializingBean {
|
||||
return StringUtils.equals(dto.getSig(), sign);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -108,28 +108,6 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
||||
System.out.println("当前类名:" + this.getClass().getSimpleName());
|
||||
}
|
||||
|
||||
// @Override
|
||||
public Map<String, String> queryTokenOld(CommonParamsDTO dto) {
|
||||
String operatorId = dto.getOperatorID();
|
||||
// 通过operatorId 查出 operatorSecret
|
||||
ThirdPartyPlatformConfig platformConfig = thirdPartyPlatformConfigService.getInfoByOperatorId(operatorId);
|
||||
if (platformConfig == null) {
|
||||
return null;
|
||||
}
|
||||
String operatorSecret = platformConfig.getOperatorSecret();
|
||||
String dataSecret = platformConfig.getDataSecret();
|
||||
String dataSecretIv = platformConfig.getDataSecretIv();
|
||||
String signSecret = platformConfig.getSignSecret();
|
||||
// 使用公共方法生成token
|
||||
Map<String, String> resultMap = generateToken(operatorSecret, dataSecret, dataSecretIv, signSecret, operatorId, dto.getData());
|
||||
|
||||
// 拼装
|
||||
|
||||
// 加密
|
||||
|
||||
return resultMap;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, String> queryToken(CommonParamsDTO dto) {
|
||||
AccessTokenVO vo = new AccessTokenVO();
|
||||
|
||||
@@ -1092,6 +1092,8 @@ public class NinaXiaPlatformServiceImpl implements ThirdPartyPlatformService {
|
||||
.printerFlag(Integer.valueOf(pileStationInfo.getPrinterFlag()))
|
||||
.barrierFlag(Integer.valueOf(pileStationInfo.getBarrierFlag()))
|
||||
.parkingLockFlag(Integer.valueOf(pileStationInfo.getParkingLockFlag()))
|
||||
// .parkNums()
|
||||
// .supportOrder()
|
||||
.build();
|
||||
String areaCode = pileStationInfo.getAreaCode(); // 330000,330200,330213
|
||||
// 根据逗号分组
|
||||
|
||||
@@ -240,4 +240,29 @@ public class ZheJiangPlatformServiceImpl implements ThirdPartyPlatformService {
|
||||
thirdPartySecretInfoVO.setOurOperatorId(Constants.OPERATORID_JIANG_SU);
|
||||
return thirdPartySecretInfoVO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 推送充电站信息
|
||||
* supervise_notification_station_info
|
||||
*/
|
||||
|
||||
/**
|
||||
* 推送充电设备接口状态信息
|
||||
* supervise_notification_connector_status
|
||||
*/
|
||||
|
||||
/**
|
||||
* 推送充电状态信息
|
||||
* supervise_notification_equip_charge_status
|
||||
*/
|
||||
|
||||
/**
|
||||
* 推送充电订单信息
|
||||
* supervise_notification_charge_order_info
|
||||
*/
|
||||
|
||||
/**
|
||||
* 推送充电站实时功率信息
|
||||
* supervise_notification_realtime_power_info
|
||||
*/
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user