mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 02:55:04 +08:00
update 联联平台service
This commit is contained in:
@@ -183,21 +183,13 @@ public class JiangSuPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
data.put("StationInfo", nrStationInfo);
|
data.put("StationInfo", nrStationInfo);
|
||||||
|
|
||||||
String jsonString = data.toString();
|
String jsonString = data.toString();
|
||||||
System.out.println("jsonString : " + jsonString);
|
// System.out.println("jsonString : " + jsonString);
|
||||||
|
|
||||||
// 获取令牌
|
// 获取令牌
|
||||||
String token = getToken(urlAddress, operatorId, operatorSecret, dataSecretIv, signSecret, dataSecret);
|
String token = getToken(urlAddress, operatorId, operatorSecret, dataSecretIv, signSecret, dataSecret);
|
||||||
System.out.println(token);
|
|
||||||
String result = HttpRequestUtil.nrSendPost(token, jsonString, url, dataSecret
|
String result = HttpRequestUtil.nrSendPost(token, jsonString, url, dataSecret
|
||||||
, dataSecretIv, operatorId, signSecret);
|
, dataSecretIv, operatorId, signSecret);
|
||||||
|
return result;
|
||||||
// 新增数据库
|
|
||||||
PushStationInfoDTO dto = new PushStationInfoDTO();
|
|
||||||
dto.setThirdPartyType(thirdPlatformType);
|
|
||||||
dto.setStationId(Long.parseLong(stationId));
|
|
||||||
|
|
||||||
commonService.insertInfo2DataBase(dto);
|
|
||||||
return thirdPlatformType + ":" + result;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -541,8 +541,9 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
, dataSecretIv, operatorId, signSecret);
|
, dataSecretIv, operatorId, signSecret);
|
||||||
|
|
||||||
// 新增数据库
|
// 新增数据库
|
||||||
thirdPartyStationRelationService.insertInfo2DataBase(thirdPlatformType, stationId);
|
// thirdPartyStationRelationService.insertInfo2DataBase(thirdPlatformType, stationId);
|
||||||
return thirdPlatformType + ":" + result;
|
// return thirdPlatformType + ":" + result;
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -618,17 +619,14 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
.totalMoney(new BigDecimal(realTimeMonitorData.getChargingAmount()).setScale(2, BigDecimal.ROUND_HALF_UP))
|
.totalMoney(new BigDecimal(realTimeMonitorData.getChargingAmount()).setScale(2, BigDecimal.ROUND_HALF_UP))
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
// 通过站点id查询相关配置信息
|
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
||||||
ThirdPartyStationRelationVO relationInfo = thirdPartyStationRelationService.selectRelationInfo(orderInfo.getStationId());
|
|
||||||
if (relationInfo == null) {
|
String operatorId = thirdPartySecretInfoVO.getTheirOperatorId();
|
||||||
return null;
|
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
||||||
}
|
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
||||||
String operatorId = relationInfo.getOperatorId();
|
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
||||||
String operatorSecret = relationInfo.getOperatorSecret();
|
String dataSecretIv = thirdPartySecretInfoVO.getTheirDataSecretIv();
|
||||||
String signSecret = relationInfo.getSignSecret();
|
String urlAddress = thirdPartySecretInfoVO.getTheirUrlPrefix();
|
||||||
String dataSecret = relationInfo.getDataSecret();
|
|
||||||
String dataSecretIv = relationInfo.getDataSecretIv();
|
|
||||||
String urlAddress = relationInfo.getUrlAddress();
|
|
||||||
|
|
||||||
String url = urlAddress + "notification_connector_charge_status";
|
String url = urlAddress + "notification_connector_charge_status";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user