update 推送宁波平台截取AreaCode

This commit is contained in:
Lemon
2024-07-30 14:20:32 +08:00
parent 9edd3d9933
commit ade1f2e81f

View File

@@ -233,6 +233,14 @@ public class ZDLServiceImpl implements ZDLService {
.stationLat(new BigDecimal(pileStationInfo.getStationLat()))
.construction(Integer.valueOf(pileStationInfo.getConstruction()))
.build();
if (StringUtils.equals(dto.getThirdPartyType(), ThirdPlatformTypeEnum.NING_BO_PLATFORM.getTypeCode())) {
String areaCode = pileStationInfo.getAreaCode(); // 330000,330200,330213
// 根据逗号分组
String[] split = StringUtils.split(areaCode, ",");
// 只取最后一部分 330213
String subAreaCode = split[split.length - 1];
info.setAreaCode(subAreaCode);
}
// 截取运营商组织机构代码(去除最后一位后的最后九位)
MerchantInfoVO merchantInfo = pileMerchantInfoService.getMerchantInfoVO(String.valueOf(pileStationInfo.getMerchantId()));
String organizationCode = merchantInfo.getOrganizationCode();