xuhy
2026-04-20 e04f8ea7976bf06c6d9deafb16e62a271f9abeb7
[fix] 巡游打卡管理--统计数据
2个文件已修改
11 ■■■■■ 已修改文件
xp-robotaxi-maintenance-boot/src/main/java/com/xiaopeng/maintenance/controller/XpCruiseCheckInRuleController.java 1 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-maintenance-boot/src/main/resources/mapper/maintenance/XpCruiseCheckInRecordMapper.xml 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-maintenance-boot/src/main/java/com/xiaopeng/maintenance/controller/XpCruiseCheckInRuleController.java
@@ -15,7 +15,6 @@
import com.xiaopeng.maintenance.vo.XpCruiseCheckInRecordQuery;
import com.xiaopeng.maintenance.vo.XpCruiseCheckInRecordVO;
import com.xiaopeng.maintenance.vo.XpCruiseCheckInStatisticsQuery;
import com.xiaopeng.maintenance.vo.XpCruiseCheckInStatisticsVO;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
xp-robotaxi-maintenance-boot/src/main/resources/mapper/maintenance/XpCruiseCheckInRecordMapper.xml
@@ -107,8 +107,18 @@
        COUNT(CASE WHEN r.field_situation = 1 THEN 1 END) AS noTraffic,
        COUNT(CASE WHEN r.field_situation = 2 THEN 1 END) AS traffic
        FROM xp_cruise_check_in_record r
        LEFT JOIN xp_cruise_check_in_rule cr ON r.cruise_check_in_rule_id = cr.id AND cr.del_flag = '0'
        LEFT JOIN xp_operations_user u ON r.operations_user_id = u.id AND u.del_flag = '0'
        LEFT JOIN xp_fleet_operations fo ON u.id = fo.operationsUserId
        LEFT JOIN xp_fleet f ON fo.fleetId = f.id
        WHERE r.del_flag = '0'
        AND r.check_in_time IS NOT NULL
        <if test="query.ruleName != null and query.ruleName != ''">
            AND cr.name LIKE CONCAT('%', #{query.ruleName}, '%')
        </if>
        <if test="query.fleet != null and query.fleet != ''">
            AND f.fleet_name LIKE CONCAT('%', #{query.fleet}, '%')
        </if>
        <if test="query.startDate != null">
            AND DATE(r.check_in_time) &gt;= #{query.startDate}
        </if>