puzhibing
2026-05-08 f827d36742456362fdc47e4f0dcf2f42f2154c95
Merge branch 'master' of http://120.76.84.145:10101/gitblit/r/java/Robotaxi into 1.0

# Conflicts:
# xp-robotaxi-itinerary-boot/src/main/java/com/xiaopeng/itinerary/service/impl/XpPricingServiceImpl.java
6个文件已修改
44 ■■■■■ 已修改文件
xp-robotaxi-itinerary-boot/src/main/java/com/xiaopeng/itinerary/service/impl/XpPricingServiceImpl.java 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/constant/I18nKeyConstant.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/service/serviceimpl/XpPointServiceImpl.java 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/resources/i18n/messages.properties 1 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/resources/i18n/messages_en_US.properties 1 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/resources/i18n/messages_zh_CN.properties 1 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-itinerary-boot/src/main/java/com/xiaopeng/itinerary/service/impl/XpPricingServiceImpl.java
@@ -488,7 +488,14 @@
                getCurrentTimeSlot()
        );
        log.info("等待时间查询参数:{}", lon + ":" + lat);
        log.info("等待时间查询结果:{}", entities.toString());
        for (XpGeoQueryEntity entity : entities) {
            log.info("等待时间查询结果:{}", entity.toString());
            log.info("等待时间查询结果 秒数:{}", entity.getSeconds());
            log.info("等待时间查询结果 状态:{}", entity.getStatus());
        }
        if (entities.isEmpty()) {
            return 1;
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/constant/I18nKeyConstant.java
@@ -106,6 +106,8 @@
    String POINT_NUMBER_PARSE_FAIL = "point.number.parse.fail";
    // 点位-名称已存在
    String POINT_NAME_EXISTS = "point.name.exists";
    // 点位-围栏下点位数量超限
    String POINT_FENCE_POINT_LIMIT_EXCEEDED = "point.fence.point.limit.exceeded";
    // 点位删除-存在关联巡游点位
    String POINT_DELETE_HAS_CRUISE_PLAN_POINT = "point.delete.has.cruise.plan.point";
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/service/serviceimpl/XpPointServiceImpl.java
@@ -81,6 +81,7 @@
public class XpPointServiceImpl extends ServiceImpl<XpPointMapper, XpPoint> implements XpPointService {
    private static final String POINT_BIZ_TYPE = "PUD";
    private static final int MAX_POINTS_PER_FENCE = 15;
    private static final int SERIAL_WIDTH = 6;
    private static final int LOCK_WAIT_SECONDS = 5;
    private static final int LOCK_LEASE_SECONDS = 30;
@@ -230,6 +231,7 @@
            if (!locked) {
                throw new ServiceException("点位编号生成繁忙,请稍后重试", I18nKeyConstant.POINT_NUMBER_LOCK_FAIL);
            }
            validateFencePointCountLimit(pointAddDto.getElectronicAreaId());
            String maxPointNumber = this.baseMapper.selectMaxPointNumber(cityPrefix, POINT_BIZ_TYPE);
            int nextSerial = 1;
            if (StringUtils.hasText(maxPointNumber)) {
@@ -350,6 +352,36 @@
        return getPinyinInitials(prefix).toUpperCase();
    }
    private void validateFencePointCountLimit(Long electronicAreaId) {
        if (electronicAreaId == null || electronicAreaId == 0L) {
            return;
        }
        XpElectronicFenceArea currentArea = xpElectronicFenceAreaService.getById(electronicAreaId);
        if (currentArea == null) {
            throw new ServiceException("运营区域不存在", I18nKeyConstant.POINT_ELECTRONIC_AREA_NOT_EXIST);
        }
        Long fenceId = currentArea.getElectronicId();
        if (fenceId == null) {
            throw new ServiceException("运营区域不存在", I18nKeyConstant.POINT_ELECTRONIC_AREA_NOT_EXIST);
        }
        List<Long> areaIds = xpElectronicFenceAreaService.lambdaQuery()
                .eq(XpElectronicFenceArea::getElectronicId, fenceId)
                .list()
                .stream()
                .map(XpElectronicFenceArea::getId)
                .filter(Objects::nonNull)
                .collect(Collectors.toList());
        if (areaIds.isEmpty()) {
            return;
        }
        long pointCount = this.lambdaQuery()
                .in(XpPoint::getElectronicAreaId, areaIds)
                .count();
        if (pointCount >= MAX_POINTS_PER_FENCE) {
            throw new ServiceException("当前围栏最多只能添加15个点位", I18nKeyConstant.POINT_FENCE_POINT_LIMIT_EXCEEDED);
        }
    }
    private static String buildPointNumberLockKey(String cityPrefix, String bizType) {
        return "xp:point:number:" + cityPrefix + ":" + bizType;
    }
xp-robotaxi-map-boot/src/main/resources/i18n/messages.properties
@@ -41,6 +41,7 @@
point.number.lock.fail=点位编号生成繁忙,请稍后重试
point.number.parse.fail=点位编号生成失败(历史编号格式异常)
point.name.exists=点位名称已存在
point.fence.point.limit.exceeded=当前围栏最多只能添加15个点位
point.delete.has.cruise.plan.point=操作失败,该点位有关联的巡游计划点位
point.enable.not.in.operating.area=当前点位不在围栏运营区域内,不能启用。
point.enable.in.prohibited.area=当前点位在禁行区内,不能启用。
xp-robotaxi-map-boot/src/main/resources/i18n/messages_en_US.properties
@@ -34,6 +34,7 @@
point.number.lock.fail=Point number generation is busy, please try again later
point.number.parse.fail=Point number generation failed (invalid historical number format)
point.name.exists=Point name already exists
point.fence.point.limit.exceeded=A maximum of 15 points can be added to a single fence
point.delete.has.cruise.plan.point=Operation failed. This point is associated with cruise plan points.
point.enable.not.in.operating.area=This point is not within the fence operating area and cannot be enabled.
point.enable.in.prohibited.area=This point is in a prohibited area and cannot be enabled.
xp-robotaxi-map-boot/src/main/resources/i18n/messages_zh_CN.properties
@@ -34,6 +34,7 @@
point.number.lock.fail=点位编号生成繁忙,请稍后重试
point.number.parse.fail=点位编号生成失败(历史编号格式异常)
point.name.exists=点位名称已存在
point.fence.point.limit.exceeded=当前围栏最多只能添加15个点位
point.delete.has.cruise.plan.point=操作失败,该点位有关联的巡游计划点位
point.enable.not.in.operating.area=当前点位不在围栏运营区域内,不能启用。
point.enable.in.prohibited.area=当前点位在禁行区内,不能启用。