mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-06-11 10:49:52 +08:00
update 联联平台Service
This commit is contained in:
@@ -10,11 +10,18 @@ public class MerchantUtils {
|
|||||||
// 希晓运营商id
|
// 希晓运营商id
|
||||||
public static final String XIXIAO_MERCHANT_ID = "35";
|
public static final String XIXIAO_MERCHANT_ID = "35";
|
||||||
|
|
||||||
|
public static final String YUAN_DA_MERCHANT_ID = "36";
|
||||||
|
|
||||||
// 是否是希晓运营商
|
// 是否是希晓运营商
|
||||||
public static boolean isXiXiaoMerchant(String merchantId) {
|
public static boolean isXiXiaoMerchant(String merchantId) {
|
||||||
return StringUtils.equals(XIXIAO_MERCHANT_ID, merchantId);
|
return StringUtils.equals(XIXIAO_MERCHANT_ID, merchantId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 是否是远大运营商
|
||||||
|
public static boolean isYuanDaMerchant(String merchantId) {
|
||||||
|
return StringUtils.equals(YUAN_DA_MERCHANT_ID, merchantId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 从统一社会信用代码中获取组织机构代码
|
* 从统一社会信用代码中获取组织机构代码
|
||||||
* @param organizationCode
|
* @param organizationCode
|
||||||
|
|||||||
@@ -458,7 +458,7 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
settingInfo.setType(thirdPlatformType);
|
settingInfo.setType(thirdPlatformType);
|
||||||
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
||||||
|
|
||||||
String operatorId = thirdPartySecretInfoVO.getTheirOperatorId();
|
String operatorId = thirdPartySecretInfoVO.getOurOperatorId();
|
||||||
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
||||||
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
||||||
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
||||||
@@ -575,25 +575,18 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public String notificationStationStatus(PushRealTimeInfoDTO dto) {
|
public String notificationStationStatus(PushRealTimeInfoDTO dto) {
|
||||||
String thirdPartyType = dto.getThirdPartyType();
|
|
||||||
String status = dto.getStatus();
|
String status = dto.getStatus();
|
||||||
String pileConnectorCode = dto.getPileConnectorCode();
|
String pileConnectorCode = dto.getPileConnectorCode();
|
||||||
|
|
||||||
// 查出该桩所属哪个站点
|
// 查询相关配置信息
|
||||||
// String pileSn = StringUtils.substring(pileConnectorCode, 0, 14);
|
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
||||||
String pileSn = YKCUtils.getPileSn(pileConnectorCode);
|
|
||||||
PileStationVO stationVO = pileStationInfoService.getStationInfoByPileSn(pileSn);
|
String operatorId = thirdPartySecretInfoVO.getOurOperatorId();
|
||||||
// 通过站点id查询相关配置信息
|
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
||||||
ThirdPartyStationRelationVO relationInfo = thirdPartyStationRelationService.selectRelationInfo(stationVO.getId());
|
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
||||||
if (relationInfo == null) {
|
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
||||||
return null;
|
String dataSecretIv = thirdPartySecretInfoVO.getTheirDataSecretIv();
|
||||||
}
|
String urlAddress = thirdPartySecretInfoVO.getTheirUrlPrefix();
|
||||||
String operatorId = relationInfo.getOperatorId();
|
|
||||||
String operatorSecret = relationInfo.getOperatorSecret();
|
|
||||||
String signSecret = relationInfo.getSignSecret();
|
|
||||||
String dataSecret = relationInfo.getDataSecret();
|
|
||||||
String dataSecretIv = relationInfo.getDataSecretIv();
|
|
||||||
String urlAddress = relationInfo.getUrlAddress();
|
|
||||||
|
|
||||||
String url = urlAddress + BusinessInformationExchangeEnum.NOTIFICATION_STATION_STATUS.getValue();
|
String url = urlAddress + BusinessInformationExchangeEnum.NOTIFICATION_STATION_STATUS.getValue();
|
||||||
ConnectorStatusInfo info = ConnectorStatusInfo.builder()
|
ConnectorStatusInfo info = ConnectorStatusInfo.builder()
|
||||||
@@ -641,7 +634,7 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
|
|
||||||
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
||||||
|
|
||||||
String operatorId = thirdPartySecretInfoVO.getTheirOperatorId();
|
String operatorId = thirdPartySecretInfoVO.getOurOperatorId();
|
||||||
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
||||||
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
||||||
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
||||||
@@ -692,7 +685,7 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
// if (relationInfo == null) {
|
// if (relationInfo == null) {
|
||||||
// return null;
|
// return null;
|
||||||
// }
|
// }
|
||||||
String operatorId = secretInfoVO.getTheirOperatorId();
|
String operatorId = secretInfoVO.getOurOperatorId();
|
||||||
String operatorSecret = secretInfoVO.getTheirOperatorSecret();
|
String operatorSecret = secretInfoVO.getTheirOperatorSecret();
|
||||||
String signSecret = secretInfoVO.getTheirSigSecret();
|
String signSecret = secretInfoVO.getTheirSigSecret();
|
||||||
String dataSecret = secretInfoVO.getTheirDataSecret();
|
String dataSecret = secretInfoVO.getTheirDataSecret();
|
||||||
@@ -801,16 +794,14 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
OrderDetail orderDetail = orderBasicInfoService.getOrderDetailByOrderCode(orderCode);
|
OrderDetail orderDetail = orderBasicInfoService.getOrderDetailByOrderCode(orderCode);
|
||||||
|
|
||||||
// 通过站点id查询相关配置信息
|
// 通过站点id查询相关配置信息
|
||||||
ThirdPartyStationRelationVO relationInfo = thirdPartyStationRelationService.selectRelationInfo(orderBasicInfo.getStationId());
|
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
||||||
if (relationInfo == null) {
|
|
||||||
return null;
|
String operatorId = thirdPartySecretInfoVO.getOurOperatorId();
|
||||||
}
|
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
||||||
String operatorId = relationInfo.getOperatorId();
|
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
||||||
String operatorSecret = relationInfo.getOperatorSecret();
|
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
||||||
String signSecret = relationInfo.getSignSecret();
|
String dataSecretIv = thirdPartySecretInfoVO.getTheirDataSecretIv();
|
||||||
String dataSecret = relationInfo.getDataSecret();
|
String urlAddress = thirdPartySecretInfoVO.getTheirUrlPrefix();
|
||||||
String dataSecretIv = relationInfo.getDataSecretIv();
|
|
||||||
String urlAddress = relationInfo.getUrlAddress();
|
|
||||||
|
|
||||||
String url = urlAddress + "notification_orderInfo";
|
String url = urlAddress + "notification_orderInfo";
|
||||||
|
|
||||||
@@ -837,7 +828,8 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
if (MerchantUtils.isXiXiaoMerchant(orderBasicInfo.getMerchantId())) {
|
if (MerchantUtils.isXiXiaoMerchant(orderBasicInfo.getMerchantId())) {
|
||||||
orderInfo.setEquipmentOwnerID(Constants.OPERATORID_XI_XIAO);
|
orderInfo.setEquipmentOwnerID(Constants.OPERATORID_XI_XIAO);
|
||||||
}
|
}
|
||||||
if (StringUtils.equals("36", String.valueOf(orderBasicInfo.getMerchantId()))) {
|
if (MerchantUtils.isYuanDaMerchant(orderBasicInfo.getMerchantId())) {
|
||||||
|
logger.info("订单号:{} 为远大运营商订单", orderBasicInfo.getOrderCode());
|
||||||
// 远大
|
// 远大
|
||||||
orderInfo.setEquipmentOwnerID(Constants.OPERATORID_YUAN_DA);
|
orderInfo.setEquipmentOwnerID(Constants.OPERATORID_YUAN_DA);
|
||||||
}
|
}
|
||||||
@@ -928,7 +920,7 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
// if (relationInfo == null) {
|
// if (relationInfo == null) {
|
||||||
// return null;
|
// return null;
|
||||||
// }
|
// }
|
||||||
String operatorId = secretInfoVO.getTheirOperatorId();
|
String operatorId = Constants.OPERATORID_LIANLIAN;
|
||||||
String operatorSecret = secretInfoVO.getTheirOperatorSecret();
|
String operatorSecret = secretInfoVO.getTheirOperatorSecret();
|
||||||
String signSecret = secretInfoVO.getTheirSigSecret();
|
String signSecret = secretInfoVO.getTheirSigSecret();
|
||||||
String dataSecret = secretInfoVO.getTheirDataSecret();
|
String dataSecret = secretInfoVO.getTheirDataSecret();
|
||||||
@@ -1068,16 +1060,14 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
vo.setChargeFeeDetail(chargeFeeDetailList);
|
vo.setChargeFeeDetail(chargeFeeDetailList);
|
||||||
|
|
||||||
// 通过站点id查询相关配置信息
|
// 通过站点id查询相关配置信息
|
||||||
ThirdPartyStationRelationVO relationInfo = thirdPartyStationRelationService.selectRelationInfo(stationId);
|
ThirdPartySecretInfoVO thirdPartySecretInfoVO = getLianLianPlatformSecretInfo();
|
||||||
if (relationInfo == null) {
|
|
||||||
return null;
|
String operatorId = thirdPartySecretInfoVO.getOurOperatorId();
|
||||||
}
|
String operatorSecret = thirdPartySecretInfoVO.getTheirOperatorSecret();
|
||||||
String operatorId = relationInfo.getOperatorId();
|
String signSecret = thirdPartySecretInfoVO.getTheirSigSecret();
|
||||||
String operatorSecret = relationInfo.getOperatorSecret();
|
String dataSecret = thirdPartySecretInfoVO.getTheirDataSecret();
|
||||||
String signSecret = relationInfo.getSignSecret();
|
String dataSecretIv = thirdPartySecretInfoVO.getTheirDataSecretIv();
|
||||||
String dataSecret = relationInfo.getDataSecret();
|
String urlAddress = thirdPartySecretInfoVO.getTheirUrlPrefix();
|
||||||
String dataSecretIv = relationInfo.getDataSecretIv();
|
|
||||||
String urlAddress = relationInfo.getUrlAddress();
|
|
||||||
|
|
||||||
String url = urlAddress + "notification_stationFee";
|
String url = urlAddress + "notification_stationFee";
|
||||||
|
|
||||||
@@ -1129,7 +1119,7 @@ public class LianLianPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
// if (relationInfo == null) {
|
// if (relationInfo == null) {
|
||||||
// return null;
|
// return null;
|
||||||
// }
|
// }
|
||||||
String operatorId = secretInfoVO.getTheirOperatorId();
|
String operatorId = Constants.OPERATORID_LIANLIAN;
|
||||||
String operatorSecret = secretInfoVO.getTheirOperatorSecret();
|
String operatorSecret = secretInfoVO.getTheirOperatorSecret();
|
||||||
String signSecret = secretInfoVO.getTheirSigSecret();
|
String signSecret = secretInfoVO.getTheirSigSecret();
|
||||||
String dataSecret = secretInfoVO.getTheirDataSecret();
|
String dataSecret = secretInfoVO.getTheirDataSecret();
|
||||||
|
|||||||
Reference in New Issue
Block a user