mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 02:55:04 +08:00
update
This commit is contained in:
@@ -32,6 +32,7 @@ import com.jsowell.pile.vo.base.ThirdPartyStationRelationVO;
|
||||
import com.jsowell.pile.vo.huawei.QueryStartChargeVO;
|
||||
import com.jsowell.pile.vo.web.PileStationVO;
|
||||
import com.jsowell.thirdparty.huawei.HuaweiServiceV2;
|
||||
import com.jsowell.thirdparty.platform.service.impl.DianXingPlatformServiceImpl;
|
||||
import com.jsowell.thirdparty.platform.service.impl.HaiNanPlatformServiceImpl;
|
||||
import com.jsowell.thirdparty.huawei.HuaWeiService;
|
||||
import com.jsowell.thirdparty.lianlian.service.LianLianService;
|
||||
@@ -49,10 +50,14 @@ import com.jsowell.thirdparty.zhongdianlian.service.ZDLService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import lombok.val;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.bouncycastle.crypto.CryptoException;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.security.NoSuchAlgorithmException;
|
||||
import java.security.NoSuchProviderException;
|
||||
import java.security.spec.InvalidKeySpecException;
|
||||
import java.text.ParseException;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -120,6 +125,9 @@ public class CommonService {
|
||||
@Autowired
|
||||
private NinaXiaPlatformServiceImpl ninaXiaPlatformService;
|
||||
|
||||
@Autowired
|
||||
private DianXingPlatformServiceImpl dianXingPlatformService;
|
||||
|
||||
@Autowired
|
||||
private RedisCache redisCache;
|
||||
|
||||
@@ -438,7 +446,7 @@ public class CommonService {
|
||||
* 统一方法推送订单信息
|
||||
* @param orderBasicInfo 订单信息
|
||||
*/
|
||||
public void commonPushOrderInfo(OrderBasicInfo orderBasicInfo) {
|
||||
public void commonPushOrderInfo(OrderBasicInfo orderBasicInfo) throws NoSuchAlgorithmException, InvalidKeySpecException, NoSuchProviderException, CryptoException {
|
||||
// 查询该站点是否推送第三方平台
|
||||
// ThirdPartyStationRelation relation = new ThirdPartyStationRelation();
|
||||
// relation.setStationId(Long.parseLong(orderBasicInfo.getStationId()));
|
||||
@@ -505,6 +513,13 @@ public class CommonService {
|
||||
// 青海平台
|
||||
qingHaiPlatformService.notificationChargeOrderInfo(orderBasicInfo.getOrderCode());
|
||||
}
|
||||
if (StringUtils.equals(ThirdPlatformTypeEnum.NING_XIA_PLATFORM.getTypeCode(), thirdPartyType)) {
|
||||
// 宁夏平台
|
||||
ninaXiaPlatformService.notificationChargeOrderInfo(orderBasicInfo.getOrderCode());
|
||||
}
|
||||
if (StringUtils.equals(ThirdPlatformTypeEnum.DIAN_XING_PLATFORM.getTypeCode(), thirdPartyType)) {
|
||||
dianXingPlatformService.notificationChargeOrderInfo(orderBasicInfo.getOrderCode());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@ public class DianXingPlatformServiceImpl implements ThirdPartyPlatformService {
|
||||
}
|
||||
// 加密参数(方法中已将 sign 放入参数中并返回)
|
||||
String recordInfoStr = Sm2Util.generateEncryptedRequestInfo(jsonObject, thirdPartySecretInfoVO.getTheirPublicSecret(), thirdPartySecretInfoVO.getOurPrivateSecret());
|
||||
String tpToken = "4121d1c9121a41d894ed5082d264db30";
|
||||
String tpToken = "e17fe5c7b0f7404c9ea31091fbb5806f";
|
||||
|
||||
// 发送请求
|
||||
String url = thirdPartySecretInfoVO.getTheirUrlPrefix();
|
||||
|
||||
@@ -463,7 +463,7 @@ public class NinaXiaPlatformServiceImpl implements ThirdPartyPlatformService {
|
||||
}
|
||||
|
||||
// 推送地址
|
||||
String url = urlAddress + "notification_orderInfo";
|
||||
String url = urlAddress + "supervise_notification_charge_order_info";
|
||||
|
||||
// 拼装成内蒙古平台所需格式对象
|
||||
ChargeOrderInfo orderInfo = transformChargeOrderInfo(orderBasicInfo, orderDetail);
|
||||
|
||||
Reference in New Issue
Block a user