yyy
2026-04-24 40c820d230b6f1638fd32dea1062f6c79600388d
1.定向服务修改
1 文件已重命名
7个文件已修改
87 ■■■■■ 已修改文件
xp-robotaxi-api/src/main/java/com/xiaopeng/api/query/operation/FenceAndStationVo.java 4 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-api/src/main/java/com/xiaopeng/api/query/operation/PointPageListListQuery.java 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/controller/XpElectronicFenceManagementController.java 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/mapper/XpPointMapper.java 4 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/service/XpPointService.java 4 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/service/serviceimpl/XpPointServiceImpl.java 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/resources/mapper/XpPointMapper.xml 39 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-operation-boot/src/main/resources/mapper/operation/XpTargetedServiceMapper.xml 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-api/src/main/java/com/xiaopeng/api/query/operation/FenceAndStationVo.java
File was renamed from xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/vo/FenceAndStationVo.java
@@ -1,4 +1,4 @@
package com.xiaopeng.map.vo;
package com.xiaopeng.api.query.operation;
import io.swagger.annotations.ApiModelProperty;
@@ -7,8 +7,6 @@
@Data
public class FenceAndStationVo {
//    1 as type, a.electronic_name as name,
//    GROUP_CONCAT(b.id) ids
    @ApiModelProperty(value = "类型 1围栏 2场站 ")
    private Integer type;
xp-robotaxi-api/src/main/java/com/xiaopeng/api/query/operation/PointPageListListQuery.java
@@ -36,12 +36,15 @@
    @ApiModelProperty(value = "点位纬度")
    private String pointLat;
    private List<FenceAndStationVo> fenceAndStationList;
    @ApiModelProperty(value = "类型 1围栏 2场站 ")
    private Integer idType;
    @ApiModelProperty(value = "fenceAndStationIds")
    private String fenceAndStationIds;
    @ApiModelProperty(value = "fenceAreaIds")
    private List<String> fenceAreaIds;
    @ApiModelProperty(value = "stationIds")
    private List<String> stationIds;
}
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/controller/XpElectronicFenceManagementController.java
@@ -3,7 +3,6 @@
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.date.DatePattern;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.date.LocalDateTimeUtil;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
@@ -24,7 +23,7 @@
import com.xiaopeng.map.constant.I18nKeyConstant;
import com.xiaopeng.map.service.*;
import com.xiaopeng.map.utils.OperationStrategyIndex;
import com.xiaopeng.map.vo.FenceAndStationVo;
import com.xiaopeng.api.query.operation.FenceAndStationVo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
@@ -92,8 +91,8 @@
    @ApiOperation(value = "获取围栏和场站数据",tags = {"管理后台-电子围栏"})
    @GetMapping(value = "/findListFenceAndStation")
    public R<List<FenceAndStationVo>> findListFenceAndStation() {
        return R.ok(xpPointService.findListFenceAndStation());
    public R<List<FenceAndStationVo>> findListFenceAndStation(String cityCode) {
        return R.ok(xpPointService.findListFenceAndStation(cityCode));
    }
    @ApiOperation(value = "获取不分页的电子围栏列表",tags = {"管理后台-电子围栏"})
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/mapper/XpPointMapper.java
@@ -9,7 +9,7 @@
import com.xiaopeng.api.vo.order.XpPointsListVo;
import com.xiaopeng.common.core.web.page.PageInfo;
import com.xiaopeng.map.query.PointByNameQuery;
import com.xiaopeng.map.vo.FenceAndStationVo;
import com.xiaopeng.api.query.operation.FenceAndStationVo;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Param;
@@ -26,7 +26,7 @@
 */
public interface XpPointMapper extends BaseMapper<XpPoint> {
    List<FenceAndStationVo> findListFenceAndStation();
    List<FenceAndStationVo> findListFenceAndStation(String cityCode);
    List<XpPoint> pointMap(@Param("query") PointMapQuery query);
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/service/XpPointService.java
@@ -16,7 +16,7 @@
import com.xiaopeng.map.dto.NearestDto;
import com.xiaopeng.map.dto.StationDetailQueryDto;
import com.xiaopeng.map.query.PointByNameQuery;
import com.xiaopeng.map.vo.FenceAndStationVo;
import com.xiaopeng.api.query.operation.FenceAndStationVo;
import com.xiaopeng.map.vo.NearestVo;
import com.xiaopeng.map.vo.OrderDistanceVo;
import com.xiaopeng.map.vo.StationDetailVo;
@@ -74,7 +74,7 @@
    boolean getInTime(LocalTime now,  Integer effectivePeriod, String effectiveTimePeriod);
    List<XpPoint> pointMap(PointMapQuery query);
    List<FenceAndStationVo> findListFenceAndStation();
    List<FenceAndStationVo> findListFenceAndStation(String cityCode);
    List<XpPoint> findList(PointListQuery query);
xp-robotaxi-map-boot/src/main/java/com/xiaopeng/map/service/serviceimpl/XpPointServiceImpl.java
@@ -18,6 +18,7 @@
import com.xiaopeng.api.model.operation.XpRegion;
import com.xiaopeng.api.model.operation.XpStation;
import com.xiaopeng.api.model.operation.XpSystemSetting;
import com.xiaopeng.api.query.operation.FenceAndStationVo;
import com.xiaopeng.api.query.operation.PointListQuery;
import com.xiaopeng.api.query.operation.PointPageListListQuery;
import com.xiaopeng.api.vo.order.XpHistoryEndPointsVo;
@@ -368,8 +369,8 @@
    }
    @Override
    public List<FenceAndStationVo> findListFenceAndStation(){
        return baseMapper.findListFenceAndStation();
    public List<FenceAndStationVo> findListFenceAndStation(String cityCode){
        return baseMapper.findListFenceAndStation(cityCode);
    }
    @Override
@@ -558,6 +559,21 @@
    @Override
    public PageInfo<XpPoint> pageList(PointPageListListQuery query) {
        if(CollUtil.isNotEmpty(query.getFenceAndStationList())){
            List<String> fenceAreaIds = new ArrayList<>();
            List<String> stationIds = new ArrayList<>();
            for (FenceAndStationVo bean : query.getFenceAndStationList()) {
                if(bean.getType()==1){
                    fenceAreaIds.addAll(StrUtil.split(bean.getIds(),",") );
                }else{
                    stationIds.addAll(StrUtil.split(bean.getIds(),",") );
                }
            }
            query.setFenceAreaIds(fenceAreaIds);
            query.setStationIds(stationIds);
        }
        PageInfo<XpPoint> pageInfo = new PageInfo<>(query.getPageNum(),query.getPageSize());
        if (StringUtils.isNotBlank(query.getPointLonAndLat())) {
            List<String> lonAndLat = query.getPointLonAndLat().trim().contains(",") ? Arrays.asList(query.getPointLonAndLat().split(",")) :
xp-robotaxi-map-boot/src/main/resources/mapper/XpPointMapper.xml
@@ -71,14 +71,21 @@
        order by distance  asc
    </select>
    <select id="findListFenceAndStation" resultType="com.xiaopeng.map.vo.FenceAndStationVo">
    <select id="findListFenceAndStation" resultType="com.xiaopeng.api.query.operation.FenceAndStationVo">
        SELECT  1 as type, a.electronic_name as name, GROUP_CONCAT(b.id) ids
        FROM xp_electronic_fence a
        INNER JOIN xp_electronic_fence_area b on b.electronic_id = a.id and b.is_deleted = 0
        WHERE a.is_deleted = 0
          <if test="cityCode != null and cityCode != ''">
              and a.city_code = #{cityCode}
        </if>
        GROUP BY a.id
        UNION ALL
        SELECT 2 as type ,s.station_name as name,s.id as ids FROM xp_station s WHERE s.is_deleted = 0
        SELECT 2 as type ,s.station_name as name,s.id as ids FROM xp_station s
         WHERE s.is_deleted = 0
        <if test="cityCode != null and cityCode != ''">
            and s.city_code = #{cityCode}
        </if>
    </select>
@@ -158,16 +165,26 @@
        left join xp_station xs on xs.id = xp.station_id
        where xp.is_deleted = 0
        <if test="query.idType != null">
            <choose>
                <when test="query.idType == 1">
                    and xefa.id in (${query.fenceAndStationIds})
                </when>
                <when test="query.idType == 2">
                    and xs.id =#{query.fenceAndStationIds}
                </when>
            </choose>
        <if test="(query.fenceAreaIds != null and query.fenceAreaIds.size() > 0) or (query.stationIds != null and query.stationIds.size() > 0)">
            and (
            <if test="query.fenceAreaIds != null and query.fenceAreaIds.size() > 0">
                xp.electronic_area_id in
                <foreach collection="query.fenceAreaIds" item="id" open="(" separator="," close=")">
                    #{id}
                </foreach>
            </if>
            <if test="query.fenceAreaIds != null and query.fenceAreaIds.size() > 0 and query.stationIds != null and query.stationIds.size() > 0">
                or
            </if>
            <if test="query.stationIds != null and query.stationIds.size() > 0">
                xp.station_id in
                <foreach collection="query.stationIds" item="id" open="(" separator="," close=")">
                    #{id}
                </foreach>
            </if>
            )
        </if>
        <if test="query.cityCode != null and query.cityCode != ''">
            and xp.city_code =  #{query.cityCode}
        </if>
xp-robotaxi-operation-boot/src/main/resources/mapper/operation/XpTargetedServiceMapper.xml
@@ -11,7 +11,7 @@
        from xp_targeted_service as a
        where a.is_deleted = 0
        <if test="query.cityCode != null and query.cityCode != ''">
            and a.cityCode = #{query.cityCode}
            and a.city_code = #{query.cityCode}
        </if>
        order by a.create_time desc
    </select>