推送第三方平台

This commit is contained in:
Guoqs
2024-08-13 14:39:53 +08:00
parent b031ea4583
commit ff7fe68b58
5 changed files with 106 additions and 9 deletions

View File

@@ -195,9 +195,9 @@ public class ZheJiangPlatformServiceImpl implements ThirdPartyPlatformService {
public Map<String, String> queryStationsInfo(QueryStationInfoDTO dto) {
int pageNo = dto.getPageNo() == null ? 1 : dto.getPageNo();
int pageSize = dto.getPageSize() == null ? 10 : dto.getPageSize();
dto.setThirdPlatformType(thirdPlatformType);
PageUtils.startPage(pageNo, pageSize);
List<ThirdPartyStationInfoVO> stationInfos = pileStationInfoService.getStationInfosByThirdParty(dto);
List<ThirdPartyStationInfoVO> stationInfos = pileStationInfoService.selectStationInfosByThirdParty(dto);
if (CollectionUtils.isEmpty(stationInfos)) {
// 未查到数据
return null;
@@ -220,7 +220,20 @@ public class ZheJiangPlatformServiceImpl implements ThirdPartyPlatformService {
stationInfo.setIsAloneApply(Integer.valueOf(pileStationInfo.getAloneApply()));
stationInfo.setIsPublicParkingLot(Integer.valueOf(pileStationInfo.getPublicParking()));
stationInfo.setCountryCode(pileStationInfo.getCountryCode());
stationInfo.setAreaCode(pileStationInfo.getAreaCode());
// 根据逗号分组
String[] split = StringUtils.split(pileStationInfo.getAreaCode(), ",");
// 只取最后一部分 330213
String subAreaCode = split[split.length - 1];
stationInfo.setAreaCode(subAreaCode);
// areaCodeCountryside
GeoCodeInfo geoCode = TermRelationTreeCoordinate.completeGeoCode(pileStationInfo.getAddress());
if (geoCode != null) {
String areaCodeCountryside = geoCode.getCounty_code();
stationInfo.setAreaCodeCountryside(areaCodeCountryside);
}
stationInfo.setAddress(pileStationInfo.getAddress());
stationInfo.setServiceTel(pileStationInfo.getStationTel());
stationInfo.setStationType(Integer.valueOf(pileStationInfo.getStationType()));
@@ -255,8 +268,7 @@ public class ZheJiangPlatformServiceImpl implements ThirdPartyPlatformService {
map.put("PageCount", pageInfo.getPages());
map.put("ItemSize", pageInfo.getTotal());
map.put("StationInfos", resultList);
Map<String, String> resultMap = ThirdPartyPlatformUtils.generateResultMap(map, thirdPartySecretInfoVO);
return resultMap;
return ThirdPartyPlatformUtils.generateResultMap(map, thirdPartySecretInfoVO);
}
// 获取平台配置密钥信息