From e40cdbe8a7ee733e3db4b8cbf2270b8a22c7b6ac Mon Sep 17 00:00:00 2001 From: "YAS\\29473" <2947326429@qq.com> Date: Mon, 7 Jul 2025 17:33:55 +0800 Subject: [PATCH] update --- .../impl/SiChuanPlatformServiceImpl.java | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/SiChuanPlatformServiceImpl.java b/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/SiChuanPlatformServiceImpl.java index bd1efc01a..66a5af7e1 100644 --- a/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/SiChuanPlatformServiceImpl.java +++ b/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/SiChuanPlatformServiceImpl.java @@ -288,10 +288,13 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService { GeoCodeInfo geoCode = TermRelationTreeCoordinate.completeGeoCode(pileStationInfo.getAddress()); if (geoCode != null) { //充换电站所在县以下行政区划代码 - stationInfo.setAreaCodeCountryside(geoCode.getCounty_code()); + stationInfo.setAreaCodeCountryside(geoCode.getTown_code()); }else{ stationInfo.setAreaCodeCountryside("12345678901"); } + if (StringUtils.isBlank(stationInfo.getAreaCodeCountryside())){ + stationInfo.setAreaCodeCountryside("12345678901"); + } stationInfo.setAddress(pileStationInfo.getAddress()); stationInfo.setServiceTel(pileStationInfo.getStationTel()); stationInfo.setStationClassification(Constants.one); //站点分类,只填1:充电站 @@ -396,12 +399,6 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService { String dataSecretIv = thirdPartySecretInfoVO.getTheirDataSecretIv(); String urlAddress = thirdPartySecretInfoVO.getTheirUrlPrefix(); - String operatorId1 = "MA01H3BQ2"; - String operatorSecret1 = thirdPartySecretInfoVO.getOurOperatorSecret(); - String dataSecret1 = thirdPartySecretInfoVO.getOurDataSecret(); - String dataSecretIv1 = thirdPartySecretInfoVO.getOurDataSecretIv(); - String signSecret1 = thirdPartySecretInfoVO.getOurSigSecret(); - // 组装中电联平台所需要的数据格式 SupStationInfoDTO info = SupStationInfoDTO.builder() @@ -477,10 +474,14 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService { GeoCodeInfo geoCode = TermRelationTreeCoordinate.completeGeoCode(pileStationInfo.getAddress()); if (geoCode != null) { //充换电站所在县以下行政区划代码 - info.setAreaCodeCountryside(geoCode.getCounty_code()); + info.setAreaCodeCountryside(geoCode.getTown_code()); }else{ info.setAreaCodeCountryside("12345678901"); } + //不允许空字符串和null值 + if (StringUtils.isBlank(info.getAreaCodeCountryside())){ + info.setAreaCodeCountryside("12345678901"); + } // 截取运营商组织机构代码(去除最后一位后的最后九位) MerchantInfoVO merchantInfo = pileMerchantInfoService.getMerchantInfoVO(String.valueOf(pileStationInfo.getMerchantId())); String organizationCode = merchantInfo.getOrganizationCode(); @@ -1241,7 +1242,7 @@ public class SiChuanPlatformServiceImpl implements ThirdPartyPlatformService { connectorInfo.setPower(new BigDecimal(pileDetailInfoVO.getRatedPower()).setScale(4, RoundingMode.HALF_UP)); connectorInfo.setNationalStandard(2); connectorInfo.setAuxPower(3); // 3-兼容12V和24V - connectorInfo.setOperateStatus(50); // 50-正常使用 + connectorInfo.setOpreateStatus(50); // 50-正常使用 /* if (!StringUtils.equals(pileDetailInfoVO.getConnectorNum(), "1")) { // 如果不是单枪,则枪口功率需要除以枪口数量