Bläddra i källkod

查堵大屏--全站

wangxx 2 dagar sedan
förälder
incheckning
1a16ae56aa
27 ändrade filer med 2770 tillägg och 0 borttagningar
  1. 415 0
      airport-admin/src/main/java/com/sundot/airport/web/controller/blocked/BlockedDashboardController.java
  2. 68 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedAreaDistributionDTO.java
  3. 68 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedBrigadeCertificateDistributionDTO.java
  4. 39 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedBrigadeRateStatsDTO.java
  5. 38 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedBrigadeStatsDTO.java
  6. 39 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedCertificateDistributionDTO.java
  7. 45 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyBrigadeLuggageStatsDTO.java
  8. 46 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyBrigadeRateStatsDTO.java
  9. 45 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyBrigadeStatsDTO.java
  10. 33 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyLuggageStatsDTO.java
  11. 34 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyRateStatsDTO.java
  12. 33 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyStatsDTO.java
  13. 75 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDashboardQueryDTO.java
  14. 26 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDashboardResultDTO.java
  15. 39 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDifficultyDistributionDTO.java
  16. 38 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDiscriminationDistributionDTO.java
  17. 39 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedItemDistributionDTO.java
  18. 39 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedItemLocationDistributionDTO.java
  19. 39 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedMissCheckReasonDistributionDTO.java
  20. 39 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedOperatingYearsDistributionDTO.java
  21. 44 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedRankingDTO.java
  22. 27 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedRateResultDTO.java
  23. 45 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedTimePeriodStatsDTO.java
  24. 252 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/mapper/BlockedDashboardMapper.java
  25. 243 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/service/IBlockedDashboardService.java
  26. 389 0
      airport-blocked/src/main/java/com/sundot/airport/blocked/service/impl/BlockedDashboardServiceImpl.java
  27. 533 0
      airport-blocked/src/main/resources/mapper/blocked/BlockedDashboardMapper.xml

+ 415 - 0
airport-admin/src/main/java/com/sundot/airport/web/controller/blocked/BlockedDashboardController.java

@@ -0,0 +1,415 @@
1
+package com.sundot.airport.web.controller.blocked;
2
+
3
+import com.sundot.airport.blocked.dto.BlockedAreaDistributionDTO;
4
+import com.sundot.airport.blocked.dto.BlockedBrigadeCertificateDistributionDTO;
5
+import com.sundot.airport.blocked.dto.BlockedBrigadeRateStatsDTO;
6
+import com.sundot.airport.blocked.dto.BlockedBrigadeStatsDTO;
7
+import com.sundot.airport.blocked.dto.BlockedCertificateDistributionDTO;
8
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeLuggageStatsDTO;
9
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeRateStatsDTO;
10
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeStatsDTO;
11
+import com.sundot.airport.blocked.dto.BlockedDailyLuggageStatsDTO;
12
+import com.sundot.airport.blocked.dto.BlockedDailyRateStatsDTO;
13
+import com.sundot.airport.blocked.dto.BlockedDailyStatsDTO;
14
+import com.sundot.airport.blocked.dto.BlockedDashboardQueryDTO;
15
+import com.sundot.airport.blocked.dto.BlockedDashboardResultDTO;
16
+import com.sundot.airport.blocked.dto.BlockedDifficultyDistributionDTO;
17
+import com.sundot.airport.blocked.dto.BlockedDiscriminationDistributionDTO;
18
+import com.sundot.airport.blocked.dto.BlockedItemDistributionDTO;
19
+import com.sundot.airport.blocked.dto.BlockedItemLocationDistributionDTO;
20
+import com.sundot.airport.blocked.dto.BlockedMissCheckReasonDistributionDTO;
21
+import com.sundot.airport.blocked.dto.BlockedOperatingYearsDistributionDTO;
22
+import com.sundot.airport.blocked.dto.BlockedRankingDTO;
23
+import com.sundot.airport.blocked.dto.BlockedRateResultDTO;
24
+import com.sundot.airport.blocked.dto.BlockedTimePeriodStatsDTO;
25
+import com.sundot.airport.blocked.service.IBlockedDashboardService;
26
+import com.sundot.airport.common.core.controller.BaseController;
27
+import com.sundot.airport.common.core.domain.AjaxResult;
28
+import io.swagger.annotations.Api;
29
+import io.swagger.annotations.ApiOperation;
30
+import org.springframework.beans.factory.annotation.Autowired;
31
+import org.springframework.web.bind.annotation.GetMapping;
32
+import org.springframework.web.bind.annotation.RequestMapping;
33
+import org.springframework.web.bind.annotation.RestController;
34
+
35
+import java.util.List;
36
+
37
+/**
38
+ * 查堵大屏Controller
39
+ * 
40
+ * @author wangxx
41
+ * @date 2026-04-15
42
+ */
43
+@Api(tags = "查堵大屏")
44
+@RestController
45
+@RequestMapping("/blocked/dashboard")
46
+public class BlockedDashboardController extends BaseController {
47
+
48
+    @Autowired
49
+    private IBlockedDashboardService blockedDashboardService;
50
+
51
+    /**
52
+     * 查询查堵总数
53
+     * 查堵总数(所有大队)=各大队每日过检行李查堵数据收集表-查堵合计件数-合计
54
+     * @param queryDTO 查询参数(开始时间、结束时间、航站楼、大队ID)
55
+     * @return 查堵统计结果
56
+     */
57
+    @ApiOperation("查询查堵总数")
58
+    @GetMapping("/totalCount")
59
+    public AjaxResult getTotalCount(BlockedDashboardQueryDTO queryDTO) {
60
+        BlockedDashboardResultDTO result = blockedDashboardService.getBlockedTotalCount(queryDTO);
61
+        return success(result);
62
+    }
63
+
64
+    /**
65
+     * 查询查堵总数柱状图数据
66
+     * 查堵总数柱状图:各大队每日过检行李查堵数据收集表-查堵合计件数-合计
67
+     * 
68
+     * @param queryDTO 查询参数(开始时间、结束时间、航站楼)
69
+     * @return 各大队查堵统计列表
70
+     */
71
+    @ApiOperation("查询查堵总数柱状图")
72
+    @GetMapping("/brigadeChart")
73
+    public AjaxResult getBrigadeChart(BlockedDashboardQueryDTO queryDTO) {
74
+        List<BlockedBrigadeStatsDTO> resultList = blockedDashboardService.getBlockedCountByBrigade(queryDTO);
75
+        return success(resultList);
76
+    }
77
+
78
+    /**
79
+     * 查询总查堵万分率(所有大队)
80
+     * 总查堵万分率(所有大队)=各大队每日过检行李查堵数据收集表-当日查堵万分率-平均值
81
+     * @param queryDTO 查询参数(开始时间、结束时间)
82
+     * @return 总查堵万分率统计结果
83
+     */
84
+    @ApiOperation("查询总查堵万分率")
85
+    @GetMapping("/totalRate")
86
+    public AjaxResult getTotalRate(BlockedDashboardQueryDTO queryDTO) {
87
+        BlockedRateResultDTO result = blockedDashboardService.getTotalBlockedRate(queryDTO);
88
+        return success(result);
89
+    }
90
+
91
+    /**
92
+     * 查询各大队查堵万分率条形图数据
93
+     * 总查堵万分率条形图:各大队每日过检行李查堵数据收集表-当日查堵万分率-平均值;
94
+     * @param queryDTO 查询参数(开始时间、结束时间)
95
+     * @return 各大队查堵万分率统计列表
96
+     */
97
+    @ApiOperation("查询查堵万分率条形图")
98
+    @GetMapping("/brigadeRateChart")
99
+    public AjaxResult getBrigadeRateChart(BlockedDashboardQueryDTO queryDTO) {
100
+        List<BlockedBrigadeRateStatsDTO> resultList = blockedDashboardService.getBlockedRateByBrigade(queryDTO);
101
+        return success(resultList);
102
+    }
103
+
104
+    /**
105
+     * 每日查堵数量(总表)
106
+     * 各大队每日过检行李查堵数据收集表-查堵合计件数-合计;
107
+     * @param queryDTO 查询参数(开始时间、结束时间)
108
+     * @return 每日查堵统计列表
109
+     */
110
+    @ApiOperation("每日查堵数量(总表)")
111
+    @GetMapping("/dailyTrend")
112
+    public AjaxResult getDailyTrend(BlockedDashboardQueryDTO queryDTO) {
113
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardService.getBlockedCountByDate(queryDTO);
114
+        return success(resultList);
115
+    }
116
+
117
+    /**
118
+     * 查询每日查堵数量大队对比表数据
119
+     * 各大队每日过检行李查堵数据收集表-查堵合计件数-合计;
120
+     * @param queryDTO 查询参数(开始时间、结束时间)
121
+     * @return 每日各大队查堵统计列表
122
+     */
123
+    @ApiOperation("每日查堵数量(大队对比)")
124
+    @GetMapping("/dailyBrigadeComparison")
125
+    public AjaxResult getDailyBrigadeComparison(BlockedDashboardQueryDTO queryDTO) {
126
+        List<BlockedDailyBrigadeStatsDTO> resultList = blockedDashboardService.getBlockedCountByDateAndBrigade(queryDTO);
127
+        return success(resultList);
128
+    }
129
+
130
+    /**
131
+     * 每日查堵万分率(总表)
132
+     * 各大队每日过检行李查堵数据收集表-当日查堵万分率-平均值;
133
+     * 
134
+     * @param queryDTO 查询参数(开始时间、结束时间)
135
+     * @return 每日查堵万分率统计列表
136
+     */
137
+    @ApiOperation("每日查堵万分率(总表)")
138
+    @GetMapping("/dailyRateTrend")
139
+    public AjaxResult getDailyRateTrend(BlockedDashboardQueryDTO queryDTO) {
140
+        List<BlockedDailyRateStatsDTO> resultList = blockedDashboardService.getBlockedRateByDate(queryDTO);
141
+        return success(resultList);
142
+    }
143
+
144
+    /**
145
+     * 每日查堵万分率(大队对比)
146
+     * 
147
+     * 各大队每日过检行李查堵数据收集表-当日查堵万分率-平均值;
148
+     * 
149
+     * @param queryDTO 查询参数(开始时间、结束时间)
150
+     * @return 每日各大队查堵万分率统计列表
151
+     */
152
+    @ApiOperation("每日查堵万分率(大队对比)")
153
+    @GetMapping("/dailyBrigadeRateComparison")
154
+    public AjaxResult getDailyBrigadeRateComparison(BlockedDashboardQueryDTO queryDTO) {
155
+        List<BlockedDailyBrigadeRateStatsDTO> resultList = blockedDashboardService.getBlockedRateByDateAndBrigade(queryDTO);
156
+        return success(resultList);
157
+    }
158
+
159
+    /**
160
+     * 每日过检图像数(行检+旅检总表)
161
+     * 各大队每日过检行李查堵数据收集表-过检行李合计-按日期加总;
162
+     * 
163
+     * @param queryDTO 查询参数(开始时间、结束时间)
164
+     * @return 每日过检行李统计列表
165
+     */
166
+    @ApiOperation("每日过检图像数(行检+旅检总表)")
167
+    @GetMapping("/dailyLuggageTrend")
168
+    public AjaxResult getDailyLuggageTrend(BlockedDashboardQueryDTO queryDTO) {
169
+        List<BlockedDailyLuggageStatsDTO> resultList = blockedDashboardService.getTotalLuggageCountByDate(queryDTO);
170
+        return success(resultList);
171
+    }
172
+
173
+    /**
174
+     * 查询每日过检图像数大队对比表数据
175
+     * 
176
+     * 各大队每日过检行李查堵数据收集表-过检行李合计-按日期合计;
177
+     * 
178
+     * @param queryDTO 查询参数(开始时间、结束时间)
179
+     * @return 每日各大队过检行李统计列表
180
+     */
181
+    @ApiOperation("每日过检图像数(行检+旅检 大队对比)")
182
+    @GetMapping("/dailyBrigadeLuggageComparison")
183
+    public AjaxResult getDailyBrigadeLuggageComparison(BlockedDashboardQueryDTO queryDTO) {
184
+        List<BlockedDailyBrigadeLuggageStatsDTO> resultList = blockedDashboardService.getTotalLuggageCountByDateAndBrigade(queryDTO);
185
+        return success(resultList);
186
+    }
187
+
188
+    /**
189
+     * 查询查堵物品分布数据
190
+     * 数据源:漏检统计表
191
+     * 
192
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
193
+     * @return 查堵物品分布统计列表
194
+     */
195
+    @ApiOperation("查堵物品分布")
196
+    @GetMapping("/itemDistribution")
197
+    public AjaxResult getItemDistribution(BlockedDashboardQueryDTO queryDTO) {
198
+        List<BlockedItemDistributionDTO> resultList = blockedDashboardService.getItemDistribution(queryDTO);
199
+        return success(resultList);
200
+    }
201
+
202
+    /**
203
+     * 查询区域查堵数据分布
204
+     * 数据源:各大队每日过检行李查堵数据收集表
205
+     * 
206
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
207
+     * @return 区域查堵数据分布统计
208
+     */
209
+    @ApiOperation("区域查堵数量分布")
210
+    @GetMapping("/areaDistribution")
211
+    public AjaxResult getAreaDistribution(BlockedDashboardQueryDTO queryDTO) {
212
+        BlockedAreaDistributionDTO result = blockedDashboardService.getAreaDistribution(queryDTO);
213
+        return success(result);
214
+    }
215
+
216
+    /**
217
+     * 查询查堵类型分布数据
218
+     * 数据源:漏检统计表
219
+     * 
220
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
221
+     * @return 查堵类型分布统计列表
222
+     */
223
+    @ApiOperation("查堵类型分布")
224
+    @GetMapping("/discriminationDistribution")
225
+    public AjaxResult getDiscriminationDistribution(BlockedDashboardQueryDTO queryDTO) {
226
+        List<BlockedDiscriminationDistributionDTO> resultList = blockedDashboardService.getDiscriminationDistribution(queryDTO);
227
+        return success(resultList);
228
+    }
229
+
230
+    /**
231
+     * 查询查堵时间段过检行李数及万分率
232
+     * 数据源:每日各时间段过检行李数
233
+     * 
234
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
235
+     * @return 时间段统计列表
236
+     */
237
+    @ApiOperation("查堵时间段过检行李数及万分率")
238
+    @GetMapping("/timePeriodStats")
239
+    public AjaxResult getTimePeriodStats(BlockedDashboardQueryDTO queryDTO) {
240
+        List<BlockedTimePeriodStatsDTO> resultList = blockedDashboardService.getTimePeriodStats(queryDTO);
241
+        return success(resultList);
242
+    }
243
+
244
+    /**
245
+     * 查询每日过检行李数及万分率
246
+     * 数据源:每日各时间段过检行李数
247
+     * 
248
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
249
+     * @return 每日统计列表
250
+     */
251
+    @ApiOperation("每日过检行李数及万分率")
252
+    @GetMapping("/dailyLuggageAndRate")
253
+    public AjaxResult getDailyLuggageAndRate(BlockedDashboardQueryDTO queryDTO) {
254
+        List<BlockedTimePeriodStatsDTO> resultList = blockedDashboardService.getDailyLuggageAndRate(queryDTO);
255
+        return success(resultList);
256
+    }
257
+
258
+    /**
259
+     * 查询查堵-AI复查图像总数
260
+     * 数据源:各大队每日过检行李查堵数据收集表
261
+     * 
262
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
263
+     * @return AI图像统计列表
264
+     */
265
+    @ApiOperation("查堵-AI复查图像总数")
266
+    @GetMapping("/aiImageStats")
267
+    public AjaxResult getAiImageStats(BlockedDashboardQueryDTO queryDTO) {
268
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardService.getAiImageStats(queryDTO);
269
+        return success(resultList);
270
+    }
271
+
272
+    /**
273
+     * 查询查堵-AI漏判图像总数
274
+     * 数据源:各大队每日过检行李查堵数据收集表
275
+     * 
276
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
277
+     * @return AI漏判图像统计列表
278
+     */
279
+    @ApiOperation("查堵-AI漏判图像总数")
280
+    @GetMapping("/aiMissImageStats")
281
+    public AjaxResult getAiMissImageStats(BlockedDashboardQueryDTO queryDTO) {
282
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardService.getAiMissImageStats(queryDTO);
283
+        return success(resultList);
284
+    }
285
+
286
+    /**
287
+     * 查询查堵-AI误判图像总数
288
+     * 数据源:各大队每日过检行李查堵数据收集表
289
+     * 
290
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
291
+     * @return AI误判图像统计列表
292
+     */
293
+    @ApiOperation("查堵-AI误判图像总数")
294
+    @GetMapping("/aiErrorImageStats")
295
+    public AjaxResult getAiErrorImageStats(BlockedDashboardQueryDTO queryDTO) {
296
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardService.getAiErrorImageStats(queryDTO);
297
+        return success(resultList);
298
+    }
299
+
300
+    /**
301
+     * 查询查堵-主管排行榜
302
+     * 数据源:漏检统计表
303
+     * 
304
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
305
+     * @return 主管排行榜列表(前30名)
306
+     */
307
+    @ApiOperation("查堵-主管排行榜")
308
+    @GetMapping("/supervisorRanking")
309
+    public AjaxResult getSupervisorRanking(BlockedDashboardQueryDTO queryDTO) {
310
+        List<BlockedRankingDTO> resultList = blockedDashboardService.getSupervisorRanking(queryDTO);
311
+        return success(resultList);
312
+    }
313
+
314
+    /**
315
+     * 查询查堵-班组排行榜
316
+     * 数据源:漏检统计表
317
+     * 
318
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
319
+     * @return 班组排行榜列表(前30名)
320
+     */
321
+    @ApiOperation("查堵-班组排行榜")
322
+    @GetMapping("/teamLeaderRanking")
323
+    public AjaxResult getTeamLeaderRanking(BlockedDashboardQueryDTO queryDTO) {
324
+        List<BlockedRankingDTO> resultList = blockedDashboardService.getTeamLeaderRanking(queryDTO);
325
+        return success(resultList);
326
+    }
327
+
328
+    /**
329
+     * 查询查堵-人员排行榜
330
+     * 数据源:漏检统计表
331
+     * 
332
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
333
+     * @return 人员排行榜列表(前30名)
334
+     */
335
+    @ApiOperation("查堵-人员排行榜")
336
+    @GetMapping("/reviewedUserRanking")
337
+    public AjaxResult getReviewedUserRanking(BlockedDashboardQueryDTO queryDTO) {
338
+        List<BlockedRankingDTO> resultList = blockedDashboardService.getReviewedUserRanking(queryDTO);
339
+        return success(resultList);
340
+    }
341
+
342
+    /**
343
+     * 查询查堵-物品位置分布
344
+     * 数据源:漏检统计表
345
+     * 
346
+     * @param queryDTO 查询参数(开始时间、结束时间、大队ID)
347
+     * @return 物品位置分布统计列表
348
+     */
349
+    @ApiOperation("查堵-物品位置分布")
350
+    @GetMapping("/itemLocationDistribution")
351
+    public AjaxResult getItemLocationDistribution(BlockedDashboardQueryDTO queryDTO) {
352
+        List<BlockedItemLocationDistributionDTO> resultList = blockedDashboardService.getItemLocationDistribution(queryDTO);
353
+        return success(resultList);
354
+    }
355
+
356
+    /**
357
+     * 查询查堵-原因分类分布
358
+     * 数据源:漏检统计表
359
+     * 
360
+     * @param queryDTO 查询参数
361
+     * @return 原因分类分布统计列表
362
+     */
363
+    @ApiOperation("查堵-原因分类分布")
364
+    @GetMapping("/missCheckReasonDistribution")
365
+    public AjaxResult getMissCheckReasonDistribution(BlockedDashboardQueryDTO queryDTO) {
366
+        List<BlockedMissCheckReasonDistributionDTO> resultList = blockedDashboardService.getMissCheckReasonDistribution(queryDTO);
367
+        return success(resultList);
368
+    }
369
+
370
+    /**
371
+     * 查询查堵-图像难易程度分布
372
+     * 数据源:漏检统计表
373
+     * 
374
+     * @param queryDTO 查询参数
375
+     * @return 难易程度分布统计列表
376
+     */
377
+    @ApiOperation("查堵-图像难易程度分布")
378
+    @GetMapping("/difficultyDistribution")
379
+    public AjaxResult getDifficultyDistribution(BlockedDashboardQueryDTO queryDTO) {
380
+        List<BlockedDifficultyDistributionDTO> resultList = blockedDashboardService.getDifficultyDistribution(queryDTO);
381
+        return success(resultList);
382
+    }
383
+
384
+    /**
385
+     * 查询查堵-开机人员持证比例
386
+     * 数据源:用户信息配置(用户表)
387
+     * 
388
+     * @param queryDTO 查询参数
389
+     * @return 证书级别分布统计列表
390
+     */
391
+    @ApiOperation("查堵-开机人员持证比例")
392
+    @GetMapping("/certificateDistribution")
393
+    public AjaxResult getCertificateDistribution(BlockedDashboardQueryDTO queryDTO) {
394
+        List<BlockedCertificateDistributionDTO> resultList = blockedDashboardService.getCertificateDistribution(queryDTO);
395
+        return success(resultList);
396
+    }
397
+
398
+    /**
399
+     * 查询大队开机人员证书分布
400
+     * 数据源:用户信息配置(用户表)
401
+     *
402
+     * @param queryDTO 查询参数
403
+     * @return 大队证书分布统计列表
404
+     */
405
+    @ApiOperation("大队开机人员证书分布")
406
+    @GetMapping("/brigadeCertificateDistribution")
407
+    public AjaxResult getBrigadeCertificateDistribution(BlockedDashboardQueryDTO queryDTO) {
408
+        List<BlockedBrigadeCertificateDistributionDTO> resultList = blockedDashboardService.getBrigadeCertificateDistribution(queryDTO);
409
+        return success(resultList);
410
+    }
411
+
412
+
413
+
414
+  
415
+}

+ 68 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedAreaDistributionDTO.java

@@ -0,0 +1,68 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+
9
+/**
10
+ * 区域查堵数据分布统计DTO(用于双轴图表)
11
+ * 
12
+ * @author wangxx
13
+ * @date 2026-04-15
14
+ */
15
+@Data
16
+@ApiModel("区域查堵数据分布统计")
17
+public class BlockedAreaDistributionDTO implements Serializable {
18
+    
19
+    private static final long serialVersionUID = 1L;
20
+
21
+    /**
22
+     * T1旅检过检行李数
23
+     */
24
+    @ApiModelProperty("T1旅检过检行李数")
25
+    private Integer t1PassengerLuggageCount;
26
+
27
+    /**
28
+     * T2旅检过检行李数
29
+     */
30
+    @ApiModelProperty("T2旅检过检行李数")
31
+    private Integer t2PassengerLuggageCount;
32
+
33
+    /**
34
+     * T1行检过检行李数
35
+     */
36
+    @ApiModelProperty("T1行检过检行李数")
37
+    private Integer t1CargoLuggageCount;
38
+
39
+    /**
40
+     * T2行检过检行李数
41
+     */
42
+    @ApiModelProperty("T2行检过检行李数")
43
+    private Integer t2CargoLuggageCount;
44
+
45
+    /**
46
+     * T1旅检查堵件数
47
+     */
48
+    @ApiModelProperty("T1旅检查堵件数")
49
+    private Integer t1PassengerBlockedCount;
50
+
51
+    /**
52
+     * T2旅检查堵件数
53
+     */
54
+    @ApiModelProperty("T2旅检查堵件数")
55
+    private Integer t2PassengerBlockedCount;
56
+
57
+    /**
58
+     * T1行检查堵件数
59
+     */
60
+    @ApiModelProperty("T1行检查堵件数")
61
+    private Integer t1CargoBlockedCount;
62
+
63
+    /**
64
+     * T2行检查堵件数
65
+     */
66
+    @ApiModelProperty("T2行检查堵件数")
67
+    private Integer t2CargoBlockedCount;
68
+}

+ 68 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedBrigadeCertificateDistributionDTO.java

@@ -0,0 +1,68 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+
9
+/**
10
+ * 大队开机人员证书分布统计DTO(用于柱状图)
11
+ * 
12
+ * @author wangxx
13
+ * @date 2026-04-15
14
+ */
15
+@Data
16
+@ApiModel("大队开机人员证书分布统计")
17
+public class BlockedBrigadeCertificateDistributionDTO implements Serializable {
18
+    
19
+    private static final long serialVersionUID = 1L;
20
+
21
+    /**
22
+     * 大队名称
23
+     */
24
+    @ApiModelProperty("大队名称")
25
+    private String brigadeName;
26
+
27
+    /**
28
+     * 大队ID
29
+     */
30
+    @ApiModelProperty("大队ID")
31
+    private Long brigadeId;
32
+
33
+    /**
34
+     * 一级证书人数
35
+     */
36
+    @ApiModelProperty("一级证书人数")
37
+    private Integer levelOneCount;
38
+
39
+    /**
40
+     * 二级证书人数
41
+     */
42
+    @ApiModelProperty("二级证书人数")
43
+    private Integer levelTwoCount;
44
+
45
+    /**
46
+     * 三级证书人数
47
+     */
48
+    @ApiModelProperty("三级证书人数")
49
+    private Integer levelThreeCount;
50
+
51
+    /**
52
+     * 四级证书人数
53
+     */
54
+    @ApiModelProperty("四级证书人数")
55
+    private Integer levelFourCount;
56
+
57
+    /**
58
+     * 五级证书人数
59
+     */
60
+    @ApiModelProperty("五级证书人数")
61
+    private Integer levelFiveCount;
62
+
63
+    /**
64
+     * 总人数
65
+     */
66
+    @ApiModelProperty("总人数")
67
+    private Integer totalCount;
68
+}

+ 39 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedBrigadeRateStatsDTO.java

@@ -0,0 +1,39 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 大队查堵万分率统计DTO(用于条形图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("大队查堵万分率统计")
18
+public class BlockedBrigadeRateStatsDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 大队ID
24
+     */
25
+    @ApiModelProperty("大队ID")
26
+    private Long brigadeId;
27
+
28
+    /**
29
+     * 大队名称
30
+     */
31
+    @ApiModelProperty("大队名称")
32
+    private String brigadeName;
33
+
34
+    /**
35
+     * 平均查堵万分率
36
+     */
37
+    @ApiModelProperty("平均查堵万分率")
38
+    private BigDecimal avgBlockedRate;
39
+}

+ 38 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedBrigadeStatsDTO.java

@@ -0,0 +1,38 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+
9
+/**
10
+ * 查堵大队统计DTO(用于柱状图)
11
+ * 
12
+ * @author wangxx
13
+ * @date 2026-04-15
14
+ */
15
+@Data
16
+@ApiModel("查堵大队统计")
17
+public class BlockedBrigadeStatsDTO implements Serializable {
18
+    
19
+    private static final long serialVersionUID = 1L;
20
+
21
+    /**
22
+     * 大队ID
23
+     */
24
+    @ApiModelProperty("大队ID")
25
+    private Long brigadeId;
26
+
27
+    /**
28
+     * 大队名称
29
+     */
30
+    @ApiModelProperty("大队名称")
31
+    private String brigadeName;
32
+
33
+    /**
34
+     * 查堵总数
35
+     */
36
+    @ApiModelProperty("查堵总数")
37
+    private Integer totalBlockedCount;
38
+}

+ 39 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedCertificateDistributionDTO.java

@@ -0,0 +1,39 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵开机人员持证比例统计DTO(用于扇形图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵开机人员持证比例统计")
18
+public class BlockedCertificateDistributionDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 证书级别
24
+     */
25
+    @ApiModelProperty("证书级别")
26
+    private String certificateLevel;
27
+
28
+    /**
29
+     * 数量
30
+     */
31
+    @ApiModelProperty("数量")
32
+    private Integer count;
33
+
34
+    /**
35
+     * 百分比
36
+     */
37
+    @ApiModelProperty("百分比")
38
+    private BigDecimal percentage;
39
+}

+ 45 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyBrigadeLuggageStatsDTO.java

@@ -0,0 +1,45 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.util.Date;
9
+
10
+/**
11
+ * 每日过检行李数大队对比统计DTO(用于多系列趋势图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("每日过检行李数大队对比统计")
18
+public class BlockedDailyBrigadeLuggageStatsDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 统计日期
24
+     */
25
+    @ApiModelProperty("统计日期")
26
+    private Date statDate;
27
+
28
+    /**
29
+     * 大队ID
30
+     */
31
+    @ApiModelProperty("大队ID")
32
+    private Long brigadeId;
33
+
34
+    /**
35
+     * 大队名称
36
+     */
37
+    @ApiModelProperty("大队名称")
38
+    private String brigadeName;
39
+
40
+    /**
41
+     * 过检行李合计
42
+     */
43
+    @ApiModelProperty("过检行李合计")
44
+    private Integer totalLuggageCount;
45
+}

+ 46 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyBrigadeRateStatsDTO.java

@@ -0,0 +1,46 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+import java.util.Date;
10
+
11
+/**
12
+ * 每日查堵万分率大队对比统计DTO(用于多系列趋势图)
13
+ * 
14
+ * @author wangxx
15
+ * @date 2026-04-15
16
+ */
17
+@Data
18
+@ApiModel("每日查堵万分率大队对比统计")
19
+public class BlockedDailyBrigadeRateStatsDTO implements Serializable {
20
+    
21
+    private static final long serialVersionUID = 1L;
22
+
23
+    /**
24
+     * 统计日期
25
+     */
26
+    @ApiModelProperty("统计日期")
27
+    private Date statDate;
28
+
29
+    /**
30
+     * 大队ID
31
+     */
32
+    @ApiModelProperty("大队ID")
33
+    private Long brigadeId;
34
+
35
+    /**
36
+     * 大队名称
37
+     */
38
+    @ApiModelProperty("大队名称")
39
+    private String brigadeName;
40
+
41
+    /**
42
+     * 平均查堵万分率
43
+     */
44
+    @ApiModelProperty("平均查堵万分率")
45
+    private BigDecimal avgBlockedRate;
46
+}

+ 45 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyBrigadeStatsDTO.java

@@ -0,0 +1,45 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.util.Date;
9
+
10
+/**
11
+ * 每日查堵大队对比统计DTO(用于多系列趋势图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("每日查堵大队对比统计")
18
+public class BlockedDailyBrigadeStatsDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 统计日期
24
+     */
25
+    @ApiModelProperty("统计日期")
26
+    private Date statDate;
27
+
28
+    /**
29
+     * 大队ID
30
+     */
31
+    @ApiModelProperty("大队ID")
32
+    private Long brigadeId;
33
+
34
+    /**
35
+     * 大队名称
36
+     */
37
+    @ApiModelProperty("大队名称")
38
+    private String brigadeName;
39
+
40
+    /**
41
+     * 查堵合计件数
42
+     */
43
+    @ApiModelProperty("查堵合计件数")
44
+    private Integer totalBlockedCount;
45
+}

+ 33 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyLuggageStatsDTO.java

@@ -0,0 +1,33 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.util.Date;
9
+
10
+/**
11
+ * 每日过检行李数统计DTO(用于趋势图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("每日过检行李数统计")
18
+public class BlockedDailyLuggageStatsDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 统计日期
24
+     */
25
+    @ApiModelProperty("统计日期")
26
+    private Date statDate;
27
+
28
+    /**
29
+     * 过检行李合计
30
+     */
31
+    @ApiModelProperty("过检行李合计")
32
+    private Integer totalLuggageCount;
33
+}

+ 34 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyRateStatsDTO.java

@@ -0,0 +1,34 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+import java.util.Date;
10
+
11
+/**
12
+ * 每日查堵万分率统计DTO(用于趋势图)
13
+ * 
14
+ * @author wangxx
15
+ * @date 2026-04-15
16
+ */
17
+@Data
18
+@ApiModel("每日查堵万分率统计")
19
+public class BlockedDailyRateStatsDTO implements Serializable {
20
+    
21
+    private static final long serialVersionUID = 1L;
22
+
23
+    /**
24
+     * 统计日期
25
+     */
26
+    @ApiModelProperty("统计日期")
27
+    private Date statDate;
28
+
29
+    /**
30
+     * 平均查堵万分率
31
+     */
32
+    @ApiModelProperty("平均查堵万分率")
33
+    private BigDecimal avgBlockedRate;
34
+}

+ 33 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDailyStatsDTO.java

@@ -0,0 +1,33 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.util.Date;
9
+
10
+/**
11
+ * 查堵每日统计DTO(用于趋势图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵每日统计")
18
+public class BlockedDailyStatsDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 统计日期
24
+     */
25
+    @ApiModelProperty("统计日期")
26
+    private Date statDate;
27
+
28
+    /**
29
+     * 查堵合计件数
30
+     */
31
+    @ApiModelProperty("查堵合计件数")
32
+    private Integer totalBlockedCount;
33
+}

+ 75 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDashboardQueryDTO.java

@@ -0,0 +1,75 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.util.Date;
9
+
10
+/**
11
+ * 查堵大屏查询参数DTO
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵大屏查询参数")
18
+public class BlockedDashboardQueryDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 开始时间
24
+     */
25
+    @ApiModelProperty("开始时间")
26
+    private Date startTime;
27
+
28
+    /**
29
+     * 结束时间
30
+     */
31
+    @ApiModelProperty("结束时间")
32
+    private Date endTime;
33
+
34
+    /**
35
+     * 航站楼:整体/T1/T2,默认整体
36
+     */
37
+    @ApiModelProperty("航站楼:整体/T1/T2,默认整体")
38
+    private String terminal;
39
+
40
+    /**
41
+     * 大队ID,默认全站(null表示全站)
42
+     */
43
+    @ApiModelProperty("大队ID,默认全站")
44
+    private Long brigadeId;
45
+
46
+    /**
47
+     * 分管主管ID
48
+     */
49
+    @ApiModelProperty("分管主管ID")
50
+    private Long supervisorId;
51
+
52
+    /**
53
+     * 分管班组长ID
54
+     */
55
+    @ApiModelProperty("分管班组长ID")
56
+    private Long teamLeaderId;
57
+
58
+    /**
59
+     * 被回查人ID
60
+     */
61
+    @ApiModelProperty("被回查人ID")
62
+    private Long reviewedUserId;
63
+
64
+    /**
65
+     * 物品位置
66
+     */
67
+    @ApiModelProperty("物品位置")
68
+    private String itemLocation;
69
+
70
+    /**
71
+     * 航站楼ID(用于原因分类分布筛选)
72
+     */
73
+    @ApiModelProperty("航站楼ID")
74
+    private Long terminalId;
75
+}

+ 26 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDashboardResultDTO.java

@@ -0,0 +1,26 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+
9
+/**
10
+ * 查堵大屏统计结果DTO
11
+ * 
12
+ * @author wangxx
13
+ * @date 2026-04-15
14
+ */
15
+@Data
16
+@ApiModel("查堵大屏统计结果")
17
+public class BlockedDashboardResultDTO implements Serializable {
18
+    
19
+    private static final long serialVersionUID = 1L;
20
+
21
+    /**
22
+     * 查堵总数
23
+     */
24
+    @ApiModelProperty("查堵总数")
25
+    private Integer totalBlockedCount;
26
+}

+ 39 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDifficultyDistributionDTO.java

@@ -0,0 +1,39 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵图像难易程度分布统计DTO(用于扇形图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵图像难易程度分布统计")
18
+public class BlockedDifficultyDistributionDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 难度级别(简单/难)
24
+     */
25
+    @ApiModelProperty("难度级别")
26
+    private String difficultyLevel;
27
+
28
+    /**
29
+     * 数量
30
+     */
31
+    @ApiModelProperty("数量")
32
+    private Integer count;
33
+
34
+    /**
35
+     * 百分比
36
+     */
37
+    @ApiModelProperty("百分比")
38
+    private BigDecimal percentage;
39
+}

+ 38 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedDiscriminationDistributionDTO.java

@@ -0,0 +1,38 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+
9
+/**
10
+ * 查堵类型分布统计DTO(用于分组柱状图)
11
+ * 
12
+ * @author wangxx
13
+ * @date 2026-04-15
14
+ */
15
+@Data
16
+@ApiModel("查堵类型分布统计")
17
+public class BlockedDiscriminationDistributionDTO implements Serializable {
18
+    
19
+    private static final long serialVersionUID = 1L;
20
+
21
+    /**
22
+     * 漏检物品名称
23
+     */
24
+    @ApiModelProperty("漏检物品名称")
25
+    private String missCheckItem;
26
+
27
+    /**
28
+     * 判别类型
29
+     */
30
+    @ApiModelProperty("判别类型")
31
+    private String discriminationType;
32
+
33
+    /**
34
+     * 数量
35
+     */
36
+    @ApiModelProperty("数量")
37
+    private Integer count;
38
+}

+ 39 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedItemDistributionDTO.java

@@ -0,0 +1,39 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵物品分布统计DTO(用于扇形图/饼图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵物品分布统计")
18
+public class BlockedItemDistributionDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 漏检物品名称
24
+     */
25
+    @ApiModelProperty("漏检物品名称")
26
+    private String missCheckItem;
27
+
28
+    /**
29
+     * 数量
30
+     */
31
+    @ApiModelProperty("数量")
32
+    private Integer count;
33
+
34
+    /**
35
+     * 百分比
36
+     */
37
+    @ApiModelProperty("百分比")
38
+    private BigDecimal percentage;
39
+}

+ 39 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedItemLocationDistributionDTO.java

@@ -0,0 +1,39 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵物品位置分布统计DTO(用于扇形图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵物品位置分布统计")
18
+public class BlockedItemLocationDistributionDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 物品位置
24
+     */
25
+    @ApiModelProperty("物品位置")
26
+    private String itemLocation;
27
+
28
+    /**
29
+     * 数量
30
+     */
31
+    @ApiModelProperty("数量")
32
+    private Integer count;
33
+
34
+    /**
35
+     * 百分比
36
+     */
37
+    @ApiModelProperty("百分比")
38
+    private BigDecimal percentage;
39
+}

+ 39 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedMissCheckReasonDistributionDTO.java

@@ -0,0 +1,39 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵漏检原因分类分布统计DTO(用于扇形图)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵漏检原因分类分布统计")
18
+public class BlockedMissCheckReasonDistributionDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 漏检原因分类
24
+     */
25
+    @ApiModelProperty("漏检原因分类")
26
+    private String missCheckReasonCategory;
27
+
28
+    /**
29
+     * 数量
30
+     */
31
+    @ApiModelProperty("数量")
32
+    private Integer count;
33
+
34
+    /**
35
+     * 百分比
36
+     */
37
+    @ApiModelProperty("百分比")
38
+    private BigDecimal percentage;
39
+}

+ 39 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedOperatingYearsDistributionDTO.java

@@ -0,0 +1,39 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵开机人员年限分布统计DTO
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵开机人员年限分布统计")
18
+public class BlockedOperatingYearsDistributionDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 开机年限
24
+     */
25
+    @ApiModelProperty("开机年限")
26
+    private String operatingYears;
27
+
28
+    /**
29
+     * 数量
30
+     */
31
+    @ApiModelProperty("数量")
32
+    private Integer count;
33
+
34
+    /**
35
+     * 百分比
36
+     */
37
+    @ApiModelProperty("百分比")
38
+    private BigDecimal percentage;
39
+}

+ 44 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedRankingDTO.java

@@ -0,0 +1,44 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+
9
+/**
10
+ * 查堵排行榜统计DTO
11
+ * 
12
+ * @author wangxx
13
+ * @date 2026-04-15
14
+ */
15
+@Data
16
+@ApiModel("查堵排行榜统计")
17
+public class BlockedRankingDTO implements Serializable {
18
+    
19
+    private static final long serialVersionUID = 1L;
20
+
21
+    /**
22
+     * 排名
23
+     */
24
+    @ApiModelProperty("排名")
25
+    private Integer rank;
26
+
27
+    /**
28
+     * 名称(主管/班组长/人员)
29
+     */
30
+    @ApiModelProperty("名称")
31
+    private String name;
32
+
33
+    /**
34
+     * ID
35
+     */
36
+    @ApiModelProperty("ID")
37
+    private Long id;
38
+
39
+    /**
40
+     * 统计记录总数
41
+     */
42
+    @ApiModelProperty("统计记录总数")
43
+    private Integer totalCount;
44
+}

+ 27 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedRateResultDTO.java

@@ -0,0 +1,27 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵万分率统计结果DTO
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵万分率统计结果")
18
+public class BlockedRateResultDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 总查堵万分率(平均值)
24
+     */
25
+    @ApiModelProperty("总查堵万分率")
26
+    private BigDecimal totalBlockedRate;
27
+}

+ 45 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/dto/BlockedTimePeriodStatsDTO.java

@@ -0,0 +1,45 @@
1
+package com.sundot.airport.blocked.dto;
2
+
3
+import io.swagger.annotations.ApiModel;
4
+import io.swagger.annotations.ApiModelProperty;
5
+import lombok.Data;
6
+
7
+import java.io.Serializable;
8
+import java.math.BigDecimal;
9
+
10
+/**
11
+ * 查堵时间段过检行李数及万分率统计DTO(用于双轴图表)
12
+ * 
13
+ * @author wangxx
14
+ * @date 2026-04-15
15
+ */
16
+@Data
17
+@ApiModel("查堵时间段过检行李数及万分率统计")
18
+public class BlockedTimePeriodStatsDTO implements Serializable {
19
+    
20
+    private static final long serialVersionUID = 1L;
21
+
22
+    /**
23
+     * 时间段
24
+     */
25
+    @ApiModelProperty("时间段")
26
+    private String timePeriod;
27
+
28
+    /**
29
+     * 过检行李数
30
+     */
31
+    @ApiModelProperty("过检行李数")
32
+    private Integer totalLuggageCount;
33
+
34
+    /**
35
+     * 查堵件数
36
+     */
37
+    @ApiModelProperty("查堵件数")
38
+    private Integer totalBlockedCount;
39
+
40
+    /**
41
+     * 查堵万分率
42
+     */
43
+    @ApiModelProperty("查堵万分率")
44
+    private BigDecimal blockRate;
45
+}

+ 252 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/mapper/BlockedDashboardMapper.java

@@ -0,0 +1,252 @@
1
+package com.sundot.airport.blocked.mapper;
2
+
3
+import com.sundot.airport.blocked.dto.BlockedAreaDistributionDTO;
4
+import com.sundot.airport.blocked.dto.BlockedBrigadeCertificateDistributionDTO;
5
+import com.sundot.airport.blocked.dto.BlockedBrigadeRateStatsDTO;
6
+import com.sundot.airport.blocked.dto.BlockedBrigadeStatsDTO;
7
+import com.sundot.airport.blocked.dto.BlockedCertificateDistributionDTO;
8
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeLuggageStatsDTO;
9
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeRateStatsDTO;
10
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeStatsDTO;
11
+import com.sundot.airport.blocked.dto.BlockedDailyLuggageStatsDTO;
12
+import com.sundot.airport.blocked.dto.BlockedDailyRateStatsDTO;
13
+import com.sundot.airport.blocked.dto.BlockedDailyStatsDTO;
14
+import com.sundot.airport.blocked.dto.BlockedDashboardQueryDTO;
15
+import com.sundot.airport.blocked.dto.BlockedDifficultyDistributionDTO;
16
+import com.sundot.airport.blocked.dto.BlockedDiscriminationDistributionDTO;
17
+import com.sundot.airport.blocked.dto.BlockedItemDistributionDTO;
18
+import com.sundot.airport.blocked.dto.BlockedItemLocationDistributionDTO;
19
+import com.sundot.airport.blocked.dto.BlockedMissCheckReasonDistributionDTO;
20
+import com.sundot.airport.blocked.dto.BlockedOperatingYearsDistributionDTO;
21
+import com.sundot.airport.blocked.dto.BlockedRankingDTO;
22
+import com.sundot.airport.blocked.dto.BlockedTimePeriodStatsDTO;
23
+import org.apache.ibatis.annotations.Mapper;
24
+import org.apache.ibatis.annotations.Param;
25
+
26
+import java.util.List;
27
+
28
+/**
29
+ * 查堵大屏Mapper接口
30
+ * 
31
+ * @author wangxx
32
+ * @date 2026-04-15
33
+ */
34
+@Mapper
35
+public interface BlockedDashboardMapper {
36
+
37
+    /**
38
+     * 查询查堵总数
39
+     * 
40
+     * @param queryDTO 查询参数
41
+     * @return 查堵总数
42
+     */
43
+    Integer selectTotalBlockedCountWithoutBrigade(BlockedDashboardQueryDTO queryDTO);
44
+
45
+    /**
46
+     * 查询查堵总数
47
+     * 
48
+     * @param queryDTO 查询参数
49
+     * @return 查堵总数
50
+     */
51
+    Integer selectTotalBlockedCountWithBrigade(BlockedDashboardQueryDTO queryDTO);
52
+
53
+    /**
54
+     * 查询各大队查堵总数(用于柱状图)
55
+     * 
56
+     * @param queryDTO 查询参数
57
+     * @return 各大队查堵统计列表
58
+     */
59
+    List<BlockedBrigadeStatsDTO> selectBlockedCountByBrigade(BlockedDashboardQueryDTO queryDTO);
60
+
61
+    /**
62
+     * 查询总查堵万分率(所有大队平均值)
63
+     * 
64
+     * @param queryDTO 查询参数
65
+     * @return 总查堵万分率
66
+     */
67
+    java.math.BigDecimal selectTotalBlockedRate(BlockedDashboardQueryDTO queryDTO);
68
+
69
+    /**
70
+     * 查询各大队平均查堵万分率(用于条形图)
71
+     * 
72
+     * @param queryDTO 查询参数
73
+     * @return 各大队查堵万分率统计列表
74
+     */
75
+    List<BlockedBrigadeRateStatsDTO> selectBlockedRateByBrigade(BlockedDashboardQueryDTO queryDTO);
76
+
77
+    /**
78
+     * 查询每日查堵合计件数(用于趋势图)
79
+     * 
80
+     * @param queryDTO 查询参数
81
+     * @return 每日查堵统计列表
82
+     */
83
+    List<BlockedDailyStatsDTO> selectBlockedCountByDate(BlockedDashboardQueryDTO queryDTO);
84
+
85
+    /**
86
+     * 查询每日各大队查堵合计件数(用于大队对比表)
87
+     * 
88
+     * @param queryDTO 查询参数
89
+     * @return 每日各大队查堵统计列表
90
+     */
91
+    List<BlockedDailyBrigadeStatsDTO> selectBlockedCountByDateAndBrigade(BlockedDashboardQueryDTO queryDTO);
92
+
93
+    /**
94
+     * 查询每日平均查堵万分率(用于趋势图)
95
+     * 
96
+     * @param queryDTO 查询参数
97
+     * @return 每日查堵万分率统计列表
98
+     */
99
+    List<BlockedDailyRateStatsDTO> selectBlockedRateByDate(BlockedDashboardQueryDTO queryDTO);
100
+
101
+    /**
102
+     * 查询每日各大队平均查堵万分率(用于大队对比表)
103
+     * 
104
+     * @param queryDTO 查询参数
105
+     * @return 每日各大队查堵万分率统计列表
106
+     */
107
+    List<BlockedDailyBrigadeRateStatsDTO> selectBlockedRateByDateAndBrigade(BlockedDashboardQueryDTO queryDTO);
108
+
109
+    /**
110
+     * 查询每日过检行李合计(用于趋势图)
111
+     * 
112
+     * @param queryDTO 查询参数
113
+     * @return 每日过检行李统计列表
114
+     */
115
+    List<BlockedDailyLuggageStatsDTO> selectTotalLuggageCountByDate(BlockedDashboardQueryDTO queryDTO);
116
+
117
+    /**
118
+     * 查询每日各大队过检行李合计(用于大队对比表)
119
+     * 
120
+     * @param queryDTO 查询参数
121
+     * @return 每日各大队过检行李统计列表
122
+     */
123
+    List<BlockedDailyBrigadeLuggageStatsDTO> selectTotalLuggageCountByDateAndBrigade(BlockedDashboardQueryDTO queryDTO);
124
+
125
+    /**
126
+     * 查询查堵物品分布(用于扇形图)
127
+     * 
128
+     * @param queryDTO 查询参数
129
+     * @return 查堵物品分布统计列表
130
+     */
131
+    List<BlockedItemDistributionDTO> selectItemDistribution(BlockedDashboardQueryDTO queryDTO);
132
+
133
+    /**
134
+     * 查询区域查堵数据分布(用于双轴图表)
135
+     * 
136
+     * @param queryDTO 查询参数
137
+     * @return 区域查堵数据分布统计
138
+     */
139
+    BlockedAreaDistributionDTO selectAreaDistribution(BlockedDashboardQueryDTO queryDTO);
140
+
141
+    /**
142
+     * 查询查堵类型分布(用于分组柱状图)
143
+     * 
144
+     * @param queryDTO 查询参数
145
+     * @return 查堵类型分布统计列表
146
+     */
147
+    List<BlockedDiscriminationDistributionDTO> selectDiscriminationDistribution(BlockedDashboardQueryDTO queryDTO);
148
+
149
+    /**
150
+     * 查询查堵时间段过检行李数及万分率(用于双轴图表)
151
+     * 
152
+     * @param queryDTO 查询参数
153
+     * @return 时间段统计列表
154
+     */
155
+    List<BlockedTimePeriodStatsDTO> selectTimePeriodStats(BlockedDashboardQueryDTO queryDTO);
156
+
157
+    /**
158
+     * 查询每日过检行李数及万分率(用于双轴图表)
159
+     * 
160
+     * @param queryDTO 查询参数
161
+     * @return 每日统计列表
162
+     */
163
+    List<BlockedTimePeriodStatsDTO> selectDailyLuggageAndRate(BlockedDashboardQueryDTO queryDTO);
164
+
165
+    /**
166
+     * 查询查堵-AI复查图像总数(用于双系列图表)
167
+     * 
168
+     * @param queryDTO 查询参数
169
+     * @return AI图像统计列表
170
+     */
171
+    List<BlockedDailyStatsDTO> selectAiImageStats(BlockedDashboardQueryDTO queryDTO);
172
+
173
+    /**
174
+     * 查询查堵-AI漏判图像总数(用于单系列图表)
175
+     * 
176
+     * @param queryDTO 查询参数
177
+     * @return AI漏判图像统计列表
178
+     */
179
+    List<BlockedDailyStatsDTO> selectAiMissImageStats(BlockedDashboardQueryDTO queryDTO);
180
+
181
+    /**
182
+     * 查询查堵-AI误判图像总数(用于单系列图表)
183
+     * 
184
+     * @param queryDTO 查询参数
185
+     * @return AI误判图像统计列表
186
+     */
187
+    List<BlockedDailyStatsDTO> selectAiErrorImageStats(BlockedDashboardQueryDTO queryDTO);
188
+
189
+    /**
190
+     * 查询查堵-主管排行榜
191
+     * 
192
+     * @param queryDTO 查询参数
193
+     * @return 主管排行榜列表
194
+     */
195
+    List<BlockedRankingDTO> selectSupervisorRanking(BlockedDashboardQueryDTO queryDTO);
196
+
197
+    /**
198
+     * 查询查堵-班组排行榜
199
+     * 
200
+     * @param queryDTO 查询参数
201
+     * @return 班组排行榜列表
202
+     */
203
+    List<BlockedRankingDTO> selectTeamLeaderRanking(BlockedDashboardQueryDTO queryDTO);
204
+
205
+    /**
206
+     * 查询查堵-人员排行榜
207
+     * 
208
+     * @param queryDTO 查询参数
209
+     * @return 人员排行榜列表
210
+     */
211
+    List<BlockedRankingDTO> selectReviewedUserRanking(BlockedDashboardQueryDTO queryDTO);
212
+
213
+    /**
214
+     * 查询查堵-物品位置分布(用于扇形图)
215
+     * 
216
+     * @param queryDTO 查询参数
217
+     * @return 物品位置分布统计列表
218
+     */
219
+    List<BlockedItemLocationDistributionDTO> selectItemLocationDistribution(BlockedDashboardQueryDTO queryDTO);
220
+
221
+    /**
222
+     * 查询查堵-原因分类分布(用于扇形图)
223
+     * 
224
+     * @param queryDTO 查询参数
225
+     * @return 原因分类分布统计列表
226
+     */
227
+    List<BlockedMissCheckReasonDistributionDTO> selectMissCheckReasonDistribution(BlockedDashboardQueryDTO queryDTO);
228
+
229
+    /**
230
+     * 查询查堵-图像难易程度分布(用于扇形图)
231
+     * 
232
+     * @param queryDTO 查询参数
233
+     * @return 难易程度分布统计列表
234
+     */
235
+    List<BlockedDifficultyDistributionDTO> selectDifficultyDistribution(BlockedDashboardQueryDTO queryDTO);
236
+
237
+    /**
238
+     * 查询查堵-开机人员持证比例(用于扇形图)
239
+     * 
240
+     * @param queryDTO 查询参数
241
+     * @return 证书级别分布统计列表
242
+     */
243
+    List<BlockedCertificateDistributionDTO> selectCertificateDistribution(BlockedDashboardQueryDTO queryDTO);
244
+
245
+    /**
246
+     * 查询大队开机人员证书分布(用于柱状图)
247
+     * 
248
+     * @param queryDTO 查询参数
249
+     * @return 大队证书分布统计列表
250
+     */
251
+    List<BlockedBrigadeCertificateDistributionDTO> selectBrigadeCertificateDistribution(BlockedDashboardQueryDTO queryDTO);
252
+}

+ 243 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/service/IBlockedDashboardService.java

@@ -0,0 +1,243 @@
1
+package com.sundot.airport.blocked.service;
2
+
3
+import com.sundot.airport.blocked.dto.BlockedAreaDistributionDTO;
4
+import com.sundot.airport.blocked.dto.BlockedBrigadeCertificateDistributionDTO;
5
+import com.sundot.airport.blocked.dto.BlockedBrigadeRateStatsDTO;
6
+import com.sundot.airport.blocked.dto.BlockedBrigadeStatsDTO;
7
+import com.sundot.airport.blocked.dto.BlockedCertificateDistributionDTO;
8
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeLuggageStatsDTO;
9
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeRateStatsDTO;
10
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeStatsDTO;
11
+import com.sundot.airport.blocked.dto.BlockedDailyLuggageStatsDTO;
12
+import com.sundot.airport.blocked.dto.BlockedDailyRateStatsDTO;
13
+import com.sundot.airport.blocked.dto.BlockedDailyStatsDTO;
14
+import com.sundot.airport.blocked.dto.BlockedDashboardQueryDTO;
15
+import com.sundot.airport.blocked.dto.BlockedDashboardResultDTO;
16
+import com.sundot.airport.blocked.dto.BlockedDifficultyDistributionDTO;
17
+import com.sundot.airport.blocked.dto.BlockedDiscriminationDistributionDTO;
18
+import com.sundot.airport.blocked.dto.BlockedItemDistributionDTO;
19
+import com.sundot.airport.blocked.dto.BlockedItemLocationDistributionDTO;
20
+import com.sundot.airport.blocked.dto.BlockedMissCheckReasonDistributionDTO;
21
+import com.sundot.airport.blocked.dto.BlockedOperatingYearsDistributionDTO;
22
+import com.sundot.airport.blocked.dto.BlockedRankingDTO;
23
+import com.sundot.airport.blocked.dto.BlockedRateResultDTO;
24
+import com.sundot.airport.blocked.dto.BlockedTimePeriodStatsDTO;
25
+
26
+import java.util.List;
27
+
28
+/**
29
+ * 查堵大屏Service接口
30
+ * 
31
+ * @author wangxx
32
+ * @date 2026-04-15
33
+ */
34
+public interface IBlockedDashboardService {
35
+
36
+    /**
37
+     * 查询查堵总数
38
+     *
39
+     * @param queryDTO 查询参数
40
+     * @return 查堵统计结果
41
+     */
42
+    BlockedDashboardResultDTO getBlockedTotalCount(BlockedDashboardQueryDTO queryDTO);
43
+
44
+    /**
45
+     * 查询各大队查堵总数(用于柱状图)
46
+     *
47
+     * @param queryDTO 查询参数
48
+     * @return 各大队查堵统计列表
49
+     */
50
+    List<BlockedBrigadeStatsDTO> getBlockedCountByBrigade(BlockedDashboardQueryDTO queryDTO);
51
+
52
+    /**
53
+     * 查询总查堵万分率(所有大队平均值)
54
+     *
55
+     * @param queryDTO 查询参数
56
+     * @return 查堵万分率统计结果
57
+     */
58
+    BlockedRateResultDTO getTotalBlockedRate(BlockedDashboardQueryDTO queryDTO);
59
+
60
+    /**
61
+     * 查询各大队平均查堵万分率(用于条形图)
62
+     *
63
+     * @param queryDTO 查询参数
64
+     * @return 各大队查堵万分率统计列表
65
+     */
66
+    List<BlockedBrigadeRateStatsDTO> getBlockedRateByBrigade(BlockedDashboardQueryDTO queryDTO);
67
+
68
+    /**
69
+     * 查询每日查堵合计件数(用于趋势图)
70
+     *
71
+     * @param queryDTO 查询参数
72
+     * @return 每日查堵统计列表
73
+     */
74
+    List<BlockedDailyStatsDTO> getBlockedCountByDate(BlockedDashboardQueryDTO queryDTO);
75
+
76
+    /**
77
+     * 查询每日各大队查堵合计件数(用于大队对比表)
78
+     *
79
+     * @param queryDTO 查询参数
80
+     * @return 每日各大队查堵统计列表
81
+     */
82
+    List<BlockedDailyBrigadeStatsDTO> getBlockedCountByDateAndBrigade(BlockedDashboardQueryDTO queryDTO);
83
+
84
+    /**
85
+     * 查询每日平均查堵万分率(用于趋势图)
86
+     *
87
+     * @param queryDTO 查询参数
88
+     * @return 每日查堵万分率统计列表
89
+     */
90
+    List<BlockedDailyRateStatsDTO> getBlockedRateByDate(BlockedDashboardQueryDTO queryDTO);
91
+
92
+    /**
93
+     * 查询每日各大队平均查堵万分率(用于大队对比表)
94
+     *
95
+     * @param queryDTO 查询参数
96
+     * @return 每日各大队查堵万分率统计列表
97
+     */
98
+    List<BlockedDailyBrigadeRateStatsDTO> getBlockedRateByDateAndBrigade(BlockedDashboardQueryDTO queryDTO);
99
+
100
+    /**
101
+     * 查询每日过检行李合计(用于趋势图)
102
+     *
103
+     * @param queryDTO 查询参数
104
+     * @return 每日过检行李统计列表
105
+     */
106
+    List<BlockedDailyLuggageStatsDTO> getTotalLuggageCountByDate(BlockedDashboardQueryDTO queryDTO);
107
+
108
+    /**
109
+     * 查询每日各大队过检行李合计(用于大队对比表)
110
+     *
111
+     * @param queryDTO 查询参数
112
+     * @return 每日各大队过检行李统计列表
113
+     */
114
+    List<BlockedDailyBrigadeLuggageStatsDTO> getTotalLuggageCountByDateAndBrigade(BlockedDashboardQueryDTO queryDTO);
115
+
116
+    /**
117
+     * 查询查堵物品分布(用于扇形图)
118
+     *
119
+     * @param queryDTO 查询参数
120
+     * @return 查堵物品分布统计列表
121
+     */
122
+    List<BlockedItemDistributionDTO> getItemDistribution(BlockedDashboardQueryDTO queryDTO);
123
+
124
+    /**
125
+     * 查询区域查堵数据分布(用于双轴图表)
126
+     *
127
+     * @param queryDTO 查询参数
128
+     * @return 区域查堵数据分布统计
129
+     */
130
+    BlockedAreaDistributionDTO getAreaDistribution(BlockedDashboardQueryDTO queryDTO);
131
+
132
+    /**
133
+     * 查询查堵类型分布(用于分组柱状图)
134
+     *
135
+     * @param queryDTO 查询参数
136
+     * @return 查堵类型分布统计列表
137
+     */
138
+    List<BlockedDiscriminationDistributionDTO> getDiscriminationDistribution(BlockedDashboardQueryDTO queryDTO);
139
+
140
+    /**
141
+     * 查询查堵时间段过检行李数及万分率(用于双轴图表)
142
+     *
143
+     * @param queryDTO 查询参数
144
+     * @return 时间段统计列表
145
+     */
146
+    List<BlockedTimePeriodStatsDTO> getTimePeriodStats(BlockedDashboardQueryDTO queryDTO);
147
+
148
+    /**
149
+     * 查询每日过检行李数及万分率(用于双轴图表)
150
+     *
151
+     * @param queryDTO 查询参数
152
+     * @return 每日统计列表
153
+     */
154
+    List<BlockedTimePeriodStatsDTO> getDailyLuggageAndRate(BlockedDashboardQueryDTO queryDTO);
155
+
156
+    /**
157
+     * 查询查堵-AI复查图像总数(用于双系列图表)
158
+     *
159
+     * @param queryDTO 查询参数
160
+     * @return AI图像统计列表
161
+     */
162
+    List<BlockedDailyStatsDTO> getAiImageStats(BlockedDashboardQueryDTO queryDTO);
163
+
164
+    /**
165
+     * 查询查堵-AI漏判图像总数(用于单系列图表)
166
+     *
167
+     * @param queryDTO 查询参数
168
+     * @return AI漏判图像统计列表
169
+     */
170
+    List<BlockedDailyStatsDTO> getAiMissImageStats(BlockedDashboardQueryDTO queryDTO);
171
+
172
+    /**
173
+     * 查询查堵-AI误判图像总数(用于单系列图表)
174
+     *
175
+     * @param queryDTO 查询参数
176
+     * @return AI误判图像统计列表
177
+     */
178
+    List<BlockedDailyStatsDTO> getAiErrorImageStats(BlockedDashboardQueryDTO queryDTO);
179
+
180
+    /**
181
+     * 查询查堵-主管排行榜
182
+     *
183
+     * @param queryDTO 查询参数
184
+     * @return 主管排行榜列表
185
+     */
186
+    List<BlockedRankingDTO> getSupervisorRanking(BlockedDashboardQueryDTO queryDTO);
187
+
188
+    /**
189
+     * 查询查堵-班组排行榜
190
+     *
191
+     * @param queryDTO 查询参数
192
+     * @return 班组排行榜列表
193
+     */
194
+    List<BlockedRankingDTO> getTeamLeaderRanking(BlockedDashboardQueryDTO queryDTO);
195
+
196
+    /**
197
+     * 查询查堵-人员排行榜
198
+     *
199
+     * @param queryDTO 查询参数
200
+     * @return 人员排行榜列表
201
+     */
202
+    List<BlockedRankingDTO> getReviewedUserRanking(BlockedDashboardQueryDTO queryDTO);
203
+
204
+    /**
205
+     * 查询查堵-物品位置分布(用于扇形图)
206
+     *
207
+     * @param queryDTO 查询参数
208
+     * @return 物品位置分布统计列表
209
+     */
210
+    List<BlockedItemLocationDistributionDTO> getItemLocationDistribution(BlockedDashboardQueryDTO queryDTO);
211
+
212
+    /**
213
+     * 查询查堵-原因分类分布(用于扇形图)
214
+     * 
215
+     * @param queryDTO 查询参数
216
+     * @return 原因分类分布统计列表
217
+     */
218
+    List<BlockedMissCheckReasonDistributionDTO> getMissCheckReasonDistribution(BlockedDashboardQueryDTO queryDTO);
219
+
220
+    /**
221
+     * 查询查堵-图像难易程度分布(用于扇形图)
222
+     * 
223
+     * @param queryDTO 查询参数
224
+     * @return 难易程度分布统计列表
225
+     */
226
+    List<BlockedDifficultyDistributionDTO> getDifficultyDistribution(BlockedDashboardQueryDTO queryDTO);
227
+
228
+    /**
229
+     * 查询查堵-开机人员持证比例(用于扇形图)
230
+     * 
231
+     * @param queryDTO 查询参数
232
+     * @return 证书级别分布统计列表
233
+     */
234
+    List<BlockedCertificateDistributionDTO> getCertificateDistribution(BlockedDashboardQueryDTO queryDTO);
235
+
236
+    /**
237
+     * 查询大队开机人员证书分布(用于柱状图)
238
+     * 
239
+     * @param queryDTO 查询参数
240
+     * @return 大队证书分布统计列表
241
+     */
242
+    List<BlockedBrigadeCertificateDistributionDTO> getBrigadeCertificateDistribution(BlockedDashboardQueryDTO queryDTO);
243
+}

+ 389 - 0
airport-blocked/src/main/java/com/sundot/airport/blocked/service/impl/BlockedDashboardServiceImpl.java

@@ -0,0 +1,389 @@
1
+package com.sundot.airport.blocked.service.impl;
2
+
3
+import cn.hutool.core.collection.CollectionUtil;
4
+import com.sundot.airport.blocked.dto.BlockedAreaDistributionDTO;
5
+import com.sundot.airport.blocked.dto.BlockedBrigadeCertificateDistributionDTO;
6
+import com.sundot.airport.blocked.dto.BlockedBrigadeRateStatsDTO;
7
+import com.sundot.airport.blocked.dto.BlockedBrigadeStatsDTO;
8
+import com.sundot.airport.blocked.dto.BlockedCertificateDistributionDTO;
9
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeLuggageStatsDTO;
10
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeRateStatsDTO;
11
+import com.sundot.airport.blocked.dto.BlockedDailyBrigadeStatsDTO;
12
+import com.sundot.airport.blocked.dto.BlockedDailyLuggageStatsDTO;
13
+import com.sundot.airport.blocked.dto.BlockedDailyRateStatsDTO;
14
+import com.sundot.airport.blocked.dto.BlockedDailyStatsDTO;
15
+import com.sundot.airport.blocked.dto.BlockedDashboardQueryDTO;
16
+import com.sundot.airport.blocked.dto.BlockedDashboardResultDTO;
17
+import com.sundot.airport.blocked.dto.BlockedDifficultyDistributionDTO;
18
+import com.sundot.airport.blocked.dto.BlockedDiscriminationDistributionDTO;
19
+import com.sundot.airport.blocked.dto.BlockedItemDistributionDTO;
20
+import com.sundot.airport.blocked.dto.BlockedItemLocationDistributionDTO;
21
+import com.sundot.airport.blocked.dto.BlockedMissCheckReasonDistributionDTO;
22
+import com.sundot.airport.blocked.dto.BlockedOperatingYearsDistributionDTO;
23
+import com.sundot.airport.blocked.dto.BlockedRankingDTO;
24
+import com.sundot.airport.blocked.dto.BlockedRateResultDTO;
25
+import com.sundot.airport.blocked.dto.BlockedTimePeriodStatsDTO;
26
+import com.sundot.airport.blocked.mapper.BlockedDashboardMapper;
27
+import com.sundot.airport.blocked.service.IBlockedDashboardService;
28
+import org.springframework.beans.factory.annotation.Autowired;
29
+import org.springframework.stereotype.Service;
30
+
31
+import java.math.BigDecimal;
32
+import java.util.Collections;
33
+import java.util.List;
34
+
35
+/**
36
+ * 查堵大屏Service业务层处理
37
+ * 
38
+ * @author wangxx
39
+ * @date 2026-04-15
40
+ */
41
+@Service
42
+public class BlockedDashboardServiceImpl implements IBlockedDashboardService {
43
+
44
+    @Autowired
45
+    private BlockedDashboardMapper blockedDashboardMapper;
46
+
47
+    /**
48
+     * 查询查堵总数
49
+     * 
50
+     * @param queryDTO 查询参数
51
+     * @return 查堵统计结果
52
+     */
53
+    @Override
54
+    public BlockedDashboardResultDTO getBlockedTotalCount(BlockedDashboardQueryDTO queryDTO) {
55
+        BlockedDashboardResultDTO result = new BlockedDashboardResultDTO();
56
+        
57
+        // 判断是否选择了大队
58
+        if (queryDTO.getBrigadeId() == null) {
59
+            // 从各大队每日过检行李查堵数据收集表统计
60
+            Integer totalCount = blockedDashboardMapper.selectTotalBlockedCountWithoutBrigade(queryDTO);
61
+            result.setTotalBlockedCount(totalCount != null ? totalCount : 0);
62
+        } else {
63
+            // 从漏检统计表统计
64
+            Integer totalCount = blockedDashboardMapper.selectTotalBlockedCountWithBrigade(queryDTO);
65
+            result.setTotalBlockedCount(totalCount != null ? totalCount : 0);
66
+        }
67
+        
68
+        return result;
69
+    }
70
+
71
+    /**
72
+     * 查询各大队查堵总数
73
+     * 
74
+     * @param queryDTO 查询参数
75
+     * @return 各大队查堵统计列表
76
+     */
77
+    @Override
78
+    public List<BlockedBrigadeStatsDTO> getBlockedCountByBrigade(BlockedDashboardQueryDTO queryDTO) {
79
+        List<BlockedBrigadeStatsDTO> resultList = blockedDashboardMapper.selectBlockedCountByBrigade(queryDTO);
80
+        return resultList != null ? resultList : Collections.emptyList();
81
+    }
82
+
83
+    /**
84
+     * 查询总查堵万分率(所有大队平均值)
85
+     * 
86
+     * @param queryDTO 查询参数
87
+     * @return 查堵万分率统计结果
88
+     */
89
+    @Override
90
+    public BlockedRateResultDTO getTotalBlockedRate(BlockedDashboardQueryDTO queryDTO) {
91
+        BlockedRateResultDTO result = new BlockedRateResultDTO();
92
+        BigDecimal totalRate = blockedDashboardMapper.selectTotalBlockedRate(queryDTO);
93
+        result.setTotalBlockedRate(totalRate != null ? totalRate : BigDecimal.ZERO);
94
+        return result;
95
+    }
96
+
97
+    /**
98
+     * 查询各大队平均查堵万分率(用于条形图)
99
+     * 
100
+     * @param queryDTO 查询参数
101
+     * @return 各大队查堵万分率统计列表
102
+     */
103
+    @Override
104
+    public List<BlockedBrigadeRateStatsDTO> getBlockedRateByBrigade(BlockedDashboardQueryDTO queryDTO) {
105
+        List<BlockedBrigadeRateStatsDTO> resultList = blockedDashboardMapper.selectBlockedRateByBrigade(queryDTO);
106
+        return resultList != null ? resultList : Collections.emptyList();
107
+    }
108
+
109
+    /**
110
+     * 查询每日查堵合计件数(用于趋势图)
111
+     * 
112
+     * @param queryDTO 查询参数
113
+     * @return 每日查堵统计列表
114
+     */
115
+    @Override
116
+    public List<BlockedDailyStatsDTO> getBlockedCountByDate(BlockedDashboardQueryDTO queryDTO) {
117
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardMapper.selectBlockedCountByDate(queryDTO);
118
+        return resultList != null ? resultList : Collections.emptyList();
119
+    }
120
+
121
+    /**
122
+     * 查询每日各大队查堵合计件数(用于大队对比表)
123
+     * 
124
+     * @param queryDTO 查询参数
125
+     * @return 每日各大队查堵统计列表
126
+     */
127
+    @Override
128
+    public List<BlockedDailyBrigadeStatsDTO> getBlockedCountByDateAndBrigade(BlockedDashboardQueryDTO queryDTO) {
129
+        List<BlockedDailyBrigadeStatsDTO> resultList = blockedDashboardMapper.selectBlockedCountByDateAndBrigade(queryDTO);
130
+        return resultList != null ? resultList : Collections.emptyList();
131
+    }
132
+
133
+    /**
134
+     * 查询每日平均查堵万分率(用于趋势图)
135
+     * 
136
+     * @param queryDTO 查询参数
137
+     * @return 每日查堵万分率统计列表
138
+     */
139
+    @Override
140
+    public List<BlockedDailyRateStatsDTO> getBlockedRateByDate(BlockedDashboardQueryDTO queryDTO) {
141
+        List<BlockedDailyRateStatsDTO> resultList = blockedDashboardMapper.selectBlockedRateByDate(queryDTO);
142
+        return resultList != null ? resultList : Collections.emptyList();
143
+    }
144
+
145
+    /**
146
+     * 查询每日各大队平均查堵万分率(用于大队对比表)
147
+     * 
148
+     * @param queryDTO 查询参数
149
+     * @return 每日各大队查堵万分率统计列表
150
+     */
151
+    @Override
152
+    public List<BlockedDailyBrigadeRateStatsDTO> getBlockedRateByDateAndBrigade(BlockedDashboardQueryDTO queryDTO) {
153
+        List<BlockedDailyBrigadeRateStatsDTO> resultList = blockedDashboardMapper.selectBlockedRateByDateAndBrigade(queryDTO);
154
+        return resultList != null ? resultList : Collections.emptyList();
155
+    }
156
+
157
+    /**
158
+     * 查询每日过检行李合计(用于趋势图)
159
+     * 
160
+     * @param queryDTO 查询参数
161
+     * @return 每日过检行李统计列表
162
+     */
163
+    @Override
164
+    public List<BlockedDailyLuggageStatsDTO> getTotalLuggageCountByDate(BlockedDashboardQueryDTO queryDTO) {
165
+        List<BlockedDailyLuggageStatsDTO> resultList = blockedDashboardMapper.selectTotalLuggageCountByDate(queryDTO);
166
+        return resultList != null ? resultList : Collections.emptyList();
167
+    }
168
+
169
+    /**
170
+     * 查询每日各大队过检行李合计(用于大队对比表)
171
+     * 
172
+     * @param queryDTO 查询参数
173
+     * @return 每日各大队过检行李统计列表
174
+     */
175
+    @Override
176
+    public List<BlockedDailyBrigadeLuggageStatsDTO> getTotalLuggageCountByDateAndBrigade(BlockedDashboardQueryDTO queryDTO) {
177
+        List<BlockedDailyBrigadeLuggageStatsDTO> resultList = blockedDashboardMapper.selectTotalLuggageCountByDateAndBrigade(queryDTO);
178
+        return resultList != null ? resultList : Collections.emptyList();
179
+    }
180
+
181
+    /**
182
+     * 查询查堵物品分布(用于扇形图)
183
+     * 
184
+     * @param queryDTO 查询参数
185
+     * @return 查堵物品分布统计列表
186
+     */
187
+    @Override
188
+    public List<BlockedItemDistributionDTO> getItemDistribution(BlockedDashboardQueryDTO queryDTO) {
189
+        List<BlockedItemDistributionDTO> resultList = blockedDashboardMapper.selectItemDistribution(queryDTO);
190
+        return resultList != null ? resultList : Collections.emptyList();
191
+    }
192
+
193
+    /**
194
+     * 查询区域查堵数据分布(用于双轴图表)
195
+     * 
196
+     * @param queryDTO 查询参数
197
+     * @return 区域查堵数据分布统计
198
+     */
199
+    @Override
200
+    public BlockedAreaDistributionDTO getAreaDistribution(BlockedDashboardQueryDTO queryDTO) {
201
+        return blockedDashboardMapper.selectAreaDistribution(queryDTO);
202
+    }
203
+
204
+    /**
205
+     * 查询查堵类型分布(用于分组柱状图)
206
+     * 
207
+     * @param queryDTO 查询参数
208
+     * @return 查堵类型分布统计列表
209
+     */
210
+    @Override
211
+    public List<BlockedDiscriminationDistributionDTO> getDiscriminationDistribution(BlockedDashboardQueryDTO queryDTO) {
212
+        List<BlockedDiscriminationDistributionDTO> resultList = blockedDashboardMapper.selectDiscriminationDistribution(queryDTO);
213
+        return resultList != null ? resultList : Collections.emptyList();
214
+    }
215
+
216
+    /**
217
+     * 查询查堵时间段过检行李数及万分率(用于双轴图表)
218
+     * 
219
+     * @param queryDTO 查询参数
220
+     * @return 时间段统计列表
221
+     */
222
+    @Override
223
+    public List<BlockedTimePeriodStatsDTO> getTimePeriodStats(BlockedDashboardQueryDTO queryDTO) {
224
+        List<BlockedTimePeriodStatsDTO> resultList = blockedDashboardMapper.selectTimePeriodStats(queryDTO);
225
+        return resultList != null ? resultList : Collections.emptyList();
226
+    }
227
+
228
+    /**
229
+     * 查询每日过检行李数及万分率(用于双轴图表)
230
+     * 
231
+     * @param queryDTO 查询参数
232
+     * @return 每日统计列表
233
+     */
234
+    @Override
235
+    public List<BlockedTimePeriodStatsDTO> getDailyLuggageAndRate(BlockedDashboardQueryDTO queryDTO) {
236
+        List<BlockedTimePeriodStatsDTO> resultList = blockedDashboardMapper.selectDailyLuggageAndRate(queryDTO);
237
+        return resultList != null ? resultList : Collections.emptyList();
238
+    }
239
+
240
+    /**
241
+     * 查询查堵-AI复查图像总数(用于双系列图表)
242
+     * 
243
+     * @param queryDTO 查询参数
244
+     * @return AI图像统计列表
245
+     */
246
+    @Override
247
+    public List<BlockedDailyStatsDTO> getAiImageStats(BlockedDashboardQueryDTO queryDTO) {
248
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardMapper.selectAiImageStats(queryDTO);
249
+        return resultList != null ? resultList : Collections.emptyList();
250
+    }
251
+
252
+    /**
253
+     * 查询查堵-AI漏判图像总数(用于单系列图表)
254
+     * 
255
+     * @param queryDTO 查询参数
256
+     * @return AI漏判图像统计列表
257
+     */
258
+    @Override
259
+    public List<BlockedDailyStatsDTO> getAiMissImageStats(BlockedDashboardQueryDTO queryDTO) {
260
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardMapper.selectAiMissImageStats(queryDTO);
261
+        return resultList != null ? resultList : Collections.emptyList();
262
+    }
263
+
264
+    /**
265
+     * 查询查堵-AI误判图像总数(用于单系列图表)
266
+     * 
267
+     * @param queryDTO 查询参数
268
+     * @return AI误判图像统计列表
269
+     */
270
+    @Override
271
+    public List<BlockedDailyStatsDTO> getAiErrorImageStats(BlockedDashboardQueryDTO queryDTO) {
272
+        List<BlockedDailyStatsDTO> resultList = blockedDashboardMapper.selectAiErrorImageStats(queryDTO);
273
+        return resultList != null ? resultList : Collections.emptyList();
274
+    }
275
+
276
+    /**
277
+     * 查询查堵-主管排行榜
278
+     * 
279
+     * @param queryDTO 查询参数
280
+     * @return 主管排行榜列表
281
+     */
282
+    @Override
283
+    public List<BlockedRankingDTO> getSupervisorRanking(BlockedDashboardQueryDTO queryDTO) {
284
+        List<BlockedRankingDTO> resultList = blockedDashboardMapper.selectSupervisorRanking(queryDTO);
285
+        if (CollectionUtil.isNotEmpty(resultList)) {
286
+            // 计算排名
287
+            for (int i = 0; i < resultList.size(); i++) {
288
+                resultList.get(i).setRank(i + 1);
289
+            }
290
+        }
291
+        return resultList != null ? resultList : Collections.emptyList();
292
+    }
293
+
294
+    /**
295
+     * 查询查堵-班组排行榜
296
+     * 
297
+     * @param queryDTO 查询参数
298
+     * @return 班组排行榜列表
299
+     */
300
+    @Override
301
+    public List<BlockedRankingDTO> getTeamLeaderRanking(BlockedDashboardQueryDTO queryDTO) {
302
+        List<BlockedRankingDTO> resultList = blockedDashboardMapper.selectTeamLeaderRanking(queryDTO);
303
+        if (CollectionUtil.isNotEmpty(resultList)) {
304
+            // 计算排名
305
+            for (int i = 0; i < resultList.size(); i++) {
306
+                resultList.get(i).setRank(i + 1);
307
+            }
308
+        }
309
+        return resultList != null ? resultList : Collections.emptyList();
310
+    }
311
+
312
+    /**
313
+     * 查询查堵-人员排行榜
314
+     * 
315
+     * @param queryDTO 查询参数
316
+     * @return 人员排行榜列表
317
+     */
318
+    @Override
319
+    public List<BlockedRankingDTO> getReviewedUserRanking(BlockedDashboardQueryDTO queryDTO) {
320
+        List<BlockedRankingDTO> resultList = blockedDashboardMapper.selectReviewedUserRanking(queryDTO);
321
+        if (CollectionUtil.isNotEmpty(resultList)) {
322
+            // 计算排名
323
+            for (int i = 0; i < resultList.size(); i++) {
324
+                resultList.get(i).setRank(i + 1);
325
+            }
326
+        }
327
+        return resultList != null ? resultList : Collections.emptyList();
328
+    }
329
+
330
+    /**
331
+     * 查询查堵-物品位置分布(用于扇形图)
332
+     * 
333
+     * @param queryDTO 查询参数
334
+     * @return 物品位置分布统计列表
335
+     */
336
+    @Override
337
+    public List<BlockedItemLocationDistributionDTO> getItemLocationDistribution(BlockedDashboardQueryDTO queryDTO) {
338
+        List<BlockedItemLocationDistributionDTO> resultList = blockedDashboardMapper.selectItemLocationDistribution(queryDTO);
339
+        return resultList != null ? resultList : Collections.emptyList();
340
+    }
341
+
342
+    /**
343
+     * 查询查堵-原因分类分布(用于扇形图)
344
+     * 
345
+     * @param queryDTO 查询参数
346
+     * @return 原因分类分布统计列表
347
+     */
348
+    @Override
349
+    public List<BlockedMissCheckReasonDistributionDTO> getMissCheckReasonDistribution(BlockedDashboardQueryDTO queryDTO) {
350
+        List<BlockedMissCheckReasonDistributionDTO> resultList = blockedDashboardMapper.selectMissCheckReasonDistribution(queryDTO);
351
+        return resultList != null ? resultList : Collections.emptyList();
352
+    }
353
+
354
+    /**
355
+     * 查询查堵-图像难易程度分布(用于扇形图)
356
+     * 
357
+     * @param queryDTO 查询参数
358
+     * @return 难易程度分布统计列表
359
+     */
360
+    @Override
361
+    public List<BlockedDifficultyDistributionDTO> getDifficultyDistribution(BlockedDashboardQueryDTO queryDTO) {
362
+        List<BlockedDifficultyDistributionDTO> resultList = blockedDashboardMapper.selectDifficultyDistribution(queryDTO);
363
+        return resultList != null ? resultList : Collections.emptyList();
364
+    }
365
+
366
+    /**
367
+     * 查询查堵-开机人员持证比例(用于扇形图)
368
+     * 
369
+     * @param queryDTO 查询参数
370
+     * @return 证书级别分布统计列表
371
+     */
372
+    @Override
373
+    public List<BlockedCertificateDistributionDTO> getCertificateDistribution(BlockedDashboardQueryDTO queryDTO) {
374
+        List<BlockedCertificateDistributionDTO> resultList = blockedDashboardMapper.selectCertificateDistribution(queryDTO);
375
+        return resultList != null ? resultList : Collections.emptyList();
376
+    }
377
+
378
+    /**
379
+     * 查询大队开机人员证书分布(用于柱状图)
380
+     * 
381
+     * @param queryDTO 查询参数
382
+     * @return 大队证书分布统计列表
383
+     */
384
+    @Override
385
+    public List<BlockedBrigadeCertificateDistributionDTO> getBrigadeCertificateDistribution(BlockedDashboardQueryDTO queryDTO) {
386
+        List<BlockedBrigadeCertificateDistributionDTO> resultList = blockedDashboardMapper.selectBrigadeCertificateDistribution(queryDTO);
387
+        return resultList != null ? resultList : Collections.emptyList();
388
+    }
389
+}

+ 533 - 0
airport-blocked/src/main/resources/mapper/blocked/BlockedDashboardMapper.xml

@@ -0,0 +1,533 @@
1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+<!DOCTYPE mapper
3
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
4
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
5
+<mapper namespace="com.sundot.airport.blocked.mapper.BlockedDashboardMapper">
6
+    
7
+    <resultMap type="java.lang.Integer" id="BlockedCountResult">
8
+        <result property="count" column="total_count"/>
9
+    </resultMap>
10
+
11
+    <!-- 查询查堵总数-->
12
+    <select id="selectTotalBlockedCountWithoutBrigade" resultType="java.lang.Integer">
13
+        SELECT COALESCE(SUM(total_blocked_count), 0) as total_count
14
+        FROM blocked_luggage_statistics_daily
15
+        WHERE del_flag = '0'
16
+        <if test="startTime != null and endTime != null">
17
+            AND stat_date &gt;= #{startTime}
18
+            AND stat_date &lt;= #{endTime}
19
+        </if>
20
+    </select>
21
+
22
+    <!-- 查询查堵总数-->
23
+    <select id="selectTotalBlockedCountWithBrigade" resultType="java.lang.Integer">
24
+        SELECT COUNT(1) as total_count
25
+        FROM blocked_miss_check_statistics
26
+        WHERE del_flag = '0'
27
+        AND brigade_id = #{brigadeId}
28
+        <if test="startTime != null and endTime != null">
29
+            AND review_date &gt;= #{startTime}
30
+            AND review_date &lt;= #{endTime}
31
+        </if>
32
+    </select>
33
+
34
+    <!-- 查询各大队查堵总数(用于柱状图) -->
35
+    <select id="selectBlockedCountByBrigade" resultType="com.sundot.airport.blocked.dto.BlockedBrigadeStatsDTO">
36
+        SELECT 
37
+            brigade_id as brigadeId,
38
+            brigade_name as brigadeName,
39
+            COALESCE(SUM(total_blocked_count), 0) as totalBlockedCount
40
+        FROM blocked_luggage_statistics_daily
41
+        WHERE del_flag = '0'
42
+        <if test="startTime != null and endTime != null">
43
+            AND stat_date &gt;= #{startTime}
44
+            AND stat_date &lt;= #{endTime}
45
+        </if>
46
+        GROUP BY brigade_id, brigade_name
47
+        ORDER BY totalBlockedCount DESC
48
+    </select>
49
+
50
+    <!-- 查询总查堵万分率(所有大队平均值) -->
51
+    <select id="selectTotalBlockedRate" resultType="java.math.BigDecimal">
52
+        SELECT COALESCE(AVG(daily_block_rate), 0) as totalBlockedRate
53
+        FROM blocked_luggage_statistics_daily
54
+        WHERE del_flag = '0'
55
+        <if test="startTime != null and endTime != null">
56
+            AND stat_date &gt;= #{startTime}
57
+            AND stat_date &lt;= #{endTime}
58
+        </if>
59
+    </select>
60
+
61
+    <!-- 查询各大队平均查堵万分率(用于条形图) -->
62
+    <select id="selectBlockedRateByBrigade" resultType="com.sundot.airport.blocked.dto.BlockedBrigadeRateStatsDTO">
63
+        SELECT 
64
+            brigade_id as brigadeId,
65
+            brigade_name as brigadeName,
66
+            COALESCE(AVG(daily_block_rate), 0) as avgBlockedRate
67
+        FROM blocked_luggage_statistics_daily
68
+        WHERE del_flag = '0'
69
+        <if test="startTime != null and endTime != null">
70
+            AND stat_date &gt;= #{startTime}
71
+            AND stat_date &lt;= #{endTime}
72
+        </if>
73
+        GROUP BY brigade_id, brigade_name
74
+        ORDER BY avgBlockedRate DESC
75
+    </select>
76
+
77
+    <!-- 查询每日查堵合计件数(用于趋势图) -->
78
+    <select id="selectBlockedCountByDate" resultType="com.sundot.airport.blocked.dto.BlockedDailyStatsDTO">
79
+        SELECT 
80
+            stat_date as statDate,
81
+            COALESCE(SUM(total_blocked_count), 0) as totalBlockedCount
82
+        FROM blocked_luggage_statistics_daily
83
+        WHERE del_flag = '0'
84
+        <if test="startTime != null and endTime != null">
85
+            AND stat_date &gt;= #{startTime}
86
+            AND stat_date &lt;= #{endTime}
87
+        </if>
88
+        GROUP BY stat_date
89
+        ORDER BY stat_date ASC
90
+    </select>
91
+
92
+    <!-- 查询每日各大队查堵合计件数(用于大队对比表) -->
93
+    <select id="selectBlockedCountByDateAndBrigade" resultType="com.sundot.airport.blocked.dto.BlockedDailyBrigadeStatsDTO">
94
+        SELECT 
95
+            stat_date as statDate,
96
+            brigade_id as brigadeId,
97
+            brigade_name as brigadeName,
98
+            COALESCE(SUM(total_blocked_count), 0) as totalBlockedCount
99
+        FROM blocked_luggage_statistics_daily
100
+        WHERE del_flag = '0'
101
+        <if test="startTime != null and endTime != null">
102
+            AND stat_date &gt;= #{startTime}
103
+            AND stat_date &lt;= #{endTime}
104
+        </if>
105
+        GROUP BY stat_date, brigade_id, brigade_name
106
+        ORDER BY stat_date ASC, brigade_id ASC
107
+    </select>
108
+
109
+    <!-- 查询每日平均查堵万分率(用于趋势图) -->
110
+    <select id="selectBlockedRateByDate" resultType="com.sundot.airport.blocked.dto.BlockedDailyRateStatsDTO">
111
+        SELECT 
112
+            stat_date as statDate,
113
+            COALESCE(AVG(daily_block_rate), 0) as avgBlockedRate
114
+        FROM blocked_luggage_statistics_daily
115
+        WHERE del_flag = '0'
116
+        <if test="startTime != null and endTime != null">
117
+            AND stat_date &gt;= #{startTime}
118
+            AND stat_date &lt;= #{endTime}
119
+        </if>
120
+        GROUP BY stat_date
121
+        ORDER BY stat_date ASC
122
+    </select>
123
+
124
+    <!-- 查询每日各大队平均查堵万分率(用于大队对比表) -->
125
+    <select id="selectBlockedRateByDateAndBrigade" resultType="com.sundot.airport.blocked.dto.BlockedDailyBrigadeRateStatsDTO">
126
+        SELECT 
127
+            stat_date as statDate,
128
+            brigade_id as brigadeId,
129
+            brigade_name as brigadeName,
130
+            COALESCE(AVG(daily_block_rate), 0) as avgBlockedRate
131
+        FROM blocked_luggage_statistics_daily
132
+        WHERE del_flag = '0'
133
+        <if test="startTime != null and endTime != null">
134
+            AND stat_date &gt;= #{startTime}
135
+            AND stat_date &lt;= #{endTime}
136
+        </if>
137
+        GROUP BY stat_date, brigade_id, brigade_name
138
+        ORDER BY stat_date ASC, brigade_id ASC
139
+    </select>
140
+
141
+    <!-- 查询每日过检行李合计(用于趋势图) -->
142
+    <select id="selectTotalLuggageCountByDate" resultType="com.sundot.airport.blocked.dto.BlockedDailyLuggageStatsDTO">
143
+        SELECT 
144
+            stat_date as statDate,
145
+            COALESCE(SUM(total_luggage_count), 0) as totalLuggageCount
146
+        FROM blocked_luggage_statistics_daily
147
+        WHERE del_flag = '0'
148
+        <if test="startTime != null and endTime != null">
149
+            AND stat_date &gt;= #{startTime}
150
+            AND stat_date &lt;= #{endTime}
151
+        </if>
152
+        GROUP BY stat_date
153
+        ORDER BY stat_date ASC
154
+    </select>
155
+
156
+    <!-- 查询每日各大队过检行李合计(用于大队对比表) -->
157
+    <select id="selectTotalLuggageCountByDateAndBrigade" resultType="com.sundot.airport.blocked.dto.BlockedDailyBrigadeLuggageStatsDTO">
158
+        SELECT 
159
+            stat_date as statDate,
160
+            brigade_id as brigadeId,
161
+            brigade_name as brigadeName,
162
+            COALESCE(SUM(total_luggage_count), 0) as totalLuggageCount
163
+        FROM blocked_luggage_statistics_daily
164
+        WHERE del_flag = '0'
165
+        <if test="startTime != null and endTime != null">
166
+            AND stat_date &gt;= #{startTime}
167
+            AND stat_date &lt;= #{endTime}
168
+        </if>
169
+        GROUP BY stat_date, brigade_id, brigade_name
170
+        ORDER BY stat_date ASC, brigade_id ASC
171
+    </select>
172
+
173
+    <!-- 查询查堵物品分布(用于扇形图) -->
174
+    <select id="selectItemDistribution" resultType="com.sundot.airport.blocked.dto.BlockedItemDistributionDTO">
175
+        SELECT 
176
+            miss_check_item as missCheckItem,
177
+            COUNT(1) as count,
178
+            ROUND(COUNT(1) * 100.0 / SUM(COUNT(1)) OVER(), 2) as percentage
179
+        FROM blocked_miss_check_statistics
180
+        WHERE del_flag = '0'
181
+        AND miss_check_item IS NOT NULL
182
+        AND miss_check_item != ''
183
+        <if test="startTime != null and endTime != null">
184
+            AND review_date &gt;= #{startTime}
185
+            AND review_date &lt;= #{endTime}
186
+        </if>
187
+        <if test="brigadeId != null">
188
+            AND brigade_id = #{brigadeId}
189
+        </if>
190
+        GROUP BY miss_check_item
191
+        ORDER BY count DESC
192
+    </select>
193
+
194
+    <!-- 查询区域查堵数据分布(用于双轴图表) -->
195
+    <select id="selectAreaDistribution" resultType="com.sundot.airport.blocked.dto.BlockedAreaDistributionDTO">
196
+        SELECT 
197
+            COALESCE(SUM(t1_travel_luggage_count), 0) as t1PassengerLuggageCount,
198
+            COALESCE(SUM(t2_travel_luggage_count), 0) as t2PassengerLuggageCount,
199
+            COALESCE(SUM(t1_walk_luggage_count), 0) as t1CargoLuggageCount,
200
+            COALESCE(SUM(t2_walk_luggage_count), 0) as t2CargoLuggageCount,
201
+            COALESCE(SUM(t1_travel_blocked_count), 0) as t1PassengerBlockedCount,
202
+            COALESCE(SUM(t2_travel_blocked_count), 0) as t2PassengerBlockedCount,
203
+            COALESCE(SUM(t1_walk_blocked_count), 0) as t1CargoBlockedCount,
204
+            COALESCE(SUM(t2_walk_blocked_count), 0) as t2CargoBlockedCount
205
+        FROM blocked_luggage_statistics_daily
206
+        WHERE del_flag = '0'
207
+        AND brigade_id IS NOT NULL
208
+        <if test="startTime != null and endTime != null">
209
+            AND stat_date &gt;= #{startTime}
210
+            AND stat_date &lt;= #{endTime}
211
+        </if>
212
+        <if test="brigadeId != null">
213
+            AND brigade_id = #{brigadeId}
214
+        </if>
215
+    </select>
216
+
217
+    <!-- 查询查堵类型分布(用于分组柱状图) -->
218
+    <select id="selectDiscriminationDistribution" resultType="com.sundot.airport.blocked.dto.BlockedDiscriminationDistributionDTO">
219
+        SELECT 
220
+            miss_check_item as missCheckItem,
221
+            discrimination_type as discriminationType,
222
+            COUNT(1) as count
223
+        FROM blocked_miss_check_statistics
224
+        WHERE del_flag = '0'
225
+        AND miss_check_item IS NOT NULL
226
+        AND miss_check_item != ''
227
+        AND discrimination_type IS NOT NULL
228
+        AND discrimination_type != ''
229
+        <if test="startTime != null and endTime != null">
230
+            AND review_date &gt;= #{startTime}
231
+            AND review_date &lt;= #{endTime}
232
+        </if>
233
+        <if test="brigadeId != null">
234
+            AND brigade_id = #{brigadeId}
235
+        </if>
236
+        GROUP BY miss_check_item, discrimination_type
237
+        ORDER BY miss_check_item, count DESC
238
+    </select>
239
+
240
+    <!-- 查询查堵时间段过检行李数及万分率(用于双轴图表) -->
241
+    <select id="selectTimePeriodStats" resultType="com.sundot.airport.blocked.dto.BlockedTimePeriodStatsDTO">
242
+        SELECT 
243
+            time_period as timePeriod,
244
+            COALESCE(SUM(total_luggage_count), 0) as totalLuggageCount,
245
+            COALESCE(SUM(total_blocked_count), 0) as totalBlockedCount,
246
+            COALESCE(AVG(blocked_rate), 0) as blockRate
247
+        FROM blocked_luggage_piece_daily
248
+        WHERE del_flag = '0'
249
+        AND time_period IS NOT NULL
250
+        AND time_period != ''
251
+        <if test="startTime != null and endTime != null">
252
+            AND stat_date &gt;= #{startTime}
253
+            AND stat_date &lt;= #{endTime}
254
+        </if>
255
+        <if test="brigadeId != null">
256
+            AND brigade_id = #{brigadeId}
257
+        </if>
258
+        GROUP BY time_period
259
+        ORDER BY MIN(time_period)
260
+    </select>
261
+
262
+    <!-- 查询每日过检行李数及万分率(用于双轴图表) -->
263
+    <select id="selectDailyLuggageAndRate" resultType="com.sundot.airport.blocked.dto.BlockedTimePeriodStatsDTO">
264
+        SELECT 
265
+            DATE_FORMAT(stat_date, '%Y-%m-%d') as timePeriod,
266
+            COALESCE(SUM(total_luggage_count), 0) as totalLuggageCount,
267
+            COALESCE(SUM(total_blocked_count), 0) as totalBlockedCount,
268
+            COALESCE(AVG(daily_block_rate), 0) as blockRate
269
+        FROM blocked_luggage_statistics_daily
270
+        WHERE del_flag = '0'
271
+        <if test="startTime != null and endTime != null">
272
+            AND stat_date &gt;= #{startTime}
273
+            AND stat_date &lt;= #{endTime}
274
+        </if>
275
+        <if test="brigadeId != null">
276
+            AND brigade_id = #{brigadeId}
277
+        </if>
278
+        GROUP BY stat_date
279
+        ORDER BY stat_date ASC
280
+    </select>
281
+
282
+    <!-- 查询查堵-AI复查图像总数(用于双系列图表) -->
283
+    <select id="selectAiImageStats" resultType="com.sundot.airport.blocked.dto.BlockedDailyStatsDTO">
284
+        SELECT 
285
+            DATE_FORMAT(stat_date, '%Y-%m-%d') as statDate,
286
+            COALESCE(SUM(ai_review_image_total), 0) as totalBlockedCount,
287
+            COALESCE(SUM(ai_mark_total), 0) as dailyBlockedCount
288
+        FROM blocked_luggage_statistics_daily
289
+        WHERE del_flag = '0'
290
+        <if test="startTime != null and endTime != null">
291
+            AND stat_date &gt;= #{startTime}
292
+            AND stat_date &lt;= #{endTime}
293
+        </if>
294
+        <if test="brigadeId != null">
295
+            AND brigade_id = #{brigadeId}
296
+        </if>
297
+        GROUP BY stat_date
298
+        ORDER BY stat_date ASC
299
+    </select>
300
+
301
+    <!-- 查询查堵-AI漏判图像总数(用于单系列图表) -->
302
+    <select id="selectAiMissImageStats" resultType="com.sundot.airport.blocked.dto.BlockedDailyStatsDTO">
303
+        SELECT 
304
+            DATE_FORMAT(stat_date, '%Y-%m-%d') as statDate,
305
+            COALESCE(SUM(ai_miss_image_total), 0) as totalBlockedCount,
306
+            0 as dailyBlockedCount
307
+        FROM blocked_luggage_statistics_daily
308
+        WHERE del_flag = '0'
309
+        <if test="startTime != null and endTime != null">
310
+            AND stat_date &gt;= #{startTime}
311
+            AND stat_date &lt;= #{endTime}
312
+        </if>
313
+        <if test="brigadeId != null">
314
+            AND brigade_id = #{brigadeId}
315
+        </if>
316
+        GROUP BY stat_date
317
+        ORDER BY stat_date ASC
318
+    </select>
319
+
320
+    <!-- 查询查堵-AI误判图像总数(用于单系列图表) -->
321
+    <select id="selectAiErrorImageStats" resultType="com.sundot.airport.blocked.dto.BlockedDailyStatsDTO">
322
+        SELECT 
323
+            DATE_FORMAT(stat_date, '%Y-%m-%d') as statDate,
324
+            COALESCE(SUM(ai_error_image_total), 0) as totalBlockedCount,
325
+            0 as dailyBlockedCount
326
+        FROM blocked_luggage_statistics_daily
327
+        WHERE del_flag = '0'
328
+        <if test="startTime != null and endTime != null">
329
+            AND stat_date &gt;= #{startTime}
330
+            AND stat_date &lt;= #{endTime}
331
+        </if>
332
+        <if test="brigadeId != null">
333
+            AND brigade_id = #{brigadeId}
334
+        </if>
335
+        GROUP BY stat_date
336
+        ORDER BY stat_date ASC
337
+    </select>
338
+
339
+    <!-- 查询查堵-主管排行榜 -->
340
+    <select id="selectSupervisorRanking" resultType="com.sundot.airport.blocked.dto.BlockedRankingDTO">
341
+        SELECT 
342
+            supervisor_name as name,
343
+            supervisor_id as id,
344
+            COUNT(1) as totalCount
345
+        FROM blocked_miss_check_statistics
346
+        WHERE del_flag = '0'
347
+        AND supervisor_name IS NOT NULL
348
+        AND supervisor_name != ''
349
+        <if test="startTime != null and endTime != null">
350
+            AND review_date &gt;= #{startTime}
351
+            AND review_date &lt;= #{endTime}
352
+        </if>
353
+        <if test="brigadeId != null">
354
+            AND brigade_id = #{brigadeId}
355
+        </if>
356
+        <if test="supervisorId != null">
357
+            AND supervisor_id = #{supervisorId}
358
+        </if>
359
+        GROUP BY supervisor_id, supervisor_name
360
+        ORDER BY totalCount DESC
361
+        LIMIT 30
362
+    </select>
363
+
364
+    <!-- 查询查堵-班组排行榜 -->
365
+    <select id="selectTeamLeaderRanking" resultType="com.sundot.airport.blocked.dto.BlockedRankingDTO">
366
+        SELECT 
367
+            team_leader_name as name,
368
+            team_leader_id as id,
369
+            COUNT(1) as totalCount
370
+        FROM blocked_miss_check_statistics
371
+        WHERE del_flag = '0'
372
+        AND team_leader_name IS NOT NULL
373
+        AND team_leader_name != ''
374
+        <if test="startTime != null and endTime != null">
375
+            AND review_date &gt;= #{startTime}
376
+            AND review_date &lt;= #{endTime}
377
+        </if>
378
+        <if test="brigadeId != null">
379
+            AND brigade_id = #{brigadeId}
380
+        </if>
381
+        <if test="teamLeaderId != null">
382
+            AND team_leader_id = #{teamLeaderId}
383
+        </if>
384
+        GROUP BY team_leader_id, team_leader_name
385
+        ORDER BY totalCount DESC
386
+        LIMIT 30
387
+    </select>
388
+
389
+    <!-- 查询查堵-人员排行榜 -->
390
+    <select id="selectReviewedUserRanking" resultType="com.sundot.airport.blocked.dto.BlockedRankingDTO">
391
+        SELECT 
392
+            reviewed_user_name as name,
393
+            reviewed_user_id as id,
394
+            COUNT(1) as totalCount
395
+        FROM blocked_miss_check_statistics
396
+        WHERE del_flag = '0'
397
+        AND reviewed_user_name IS NOT NULL
398
+        AND reviewed_user_name != ''
399
+        <if test="startTime != null and endTime != null">
400
+            AND review_date &gt;= #{startTime}
401
+            AND review_date &lt;= #{endTime}
402
+        </if>
403
+        <if test="brigadeId != null">
404
+            AND brigade_id = #{brigadeId}
405
+        </if>
406
+        <if test="reviewedUserId != null">
407
+            AND reviewed_user_id = #{reviewedUserId}
408
+        </if>
409
+        GROUP BY reviewed_user_id, reviewed_user_name
410
+        ORDER BY totalCount DESC
411
+        LIMIT 30
412
+    </select>
413
+
414
+    <!-- 查询查堵-物品位置分布(用于扇形图) -->
415
+    <select id="selectItemLocationDistribution" resultType="com.sundot.airport.blocked.dto.BlockedItemLocationDistributionDTO">
416
+        SELECT 
417
+            item_location as itemLocation,
418
+            COUNT(1) as count,
419
+            ROUND(COUNT(1) * 100.0 / SUM(COUNT(1)) OVER(), 2) as percentage
420
+        FROM blocked_miss_check_statistics
421
+        WHERE del_flag = '0'
422
+        AND item_location IS NOT NULL
423
+        AND item_location != ''
424
+        <if test="startTime != null and endTime != null">
425
+            AND review_date &gt;= #{startTime}
426
+            AND review_date &lt;= #{endTime}
427
+        </if>
428
+        <if test="brigadeId != null">
429
+            AND brigade_id = #{brigadeId}
430
+        </if>
431
+        <if test="itemLocation != null and itemLocation != ''">
432
+            AND item_location = #{itemLocation}
433
+        </if>
434
+        GROUP BY item_location
435
+        ORDER BY count DESC
436
+    </select>
437
+
438
+    <!-- 查询查堵-原因分类分布(用于扇形图) -->
439
+    <select id="selectMissCheckReasonDistribution" resultType="com.sundot.airport.blocked.dto.BlockedMissCheckReasonDistributionDTO">
440
+        SELECT 
441
+            miss_check_reason_category as missCheckReasonCategory,
442
+            COUNT(1) as count,
443
+            ROUND(COUNT(1) * 100.0 / SUM(COUNT(1)) OVER(), 2) as percentage
444
+        FROM blocked_miss_check_statistics
445
+        WHERE del_flag = '0'
446
+        AND area_id IS NOT NULL
447
+        AND miss_check_reason_category IS NOT NULL
448
+        AND miss_check_reason_category != ''
449
+        <if test="startTime != null and endTime != null">
450
+            AND review_date &gt;= #{startTime}
451
+            AND review_date &lt;= #{endTime}
452
+        </if>
453
+        <if test="brigadeId != null">
454
+            AND brigade_id = #{brigadeId}
455
+        </if>
456
+        <if test="terminalId != null">
457
+            AND terminal_id = #{terminalId}
458
+        </if>
459
+        GROUP BY miss_check_reason_category
460
+        ORDER BY count DESC
461
+    </select>
462
+
463
+    <!-- 查询查堵-图像难易程度分布(用于扇形图) -->
464
+    <select id="selectDifficultyDistribution" resultType="com.sundot.airport.blocked.dto.BlockedDifficultyDistributionDTO">
465
+        SELECT 
466
+            difficulty_level as difficultyLevel,
467
+            COUNT(1) as count,
468
+            ROUND(COUNT(1) * 100.0 / SUM(COUNT(1)) OVER(), 2) as percentage
469
+        FROM blocked_miss_check_statistics
470
+        WHERE del_flag = '0'
471
+        AND difficulty_level IS NOT NULL
472
+        AND difficulty_level != ''
473
+        <if test="startTime != null and endTime != null">
474
+            AND review_date &gt;= #{startTime}
475
+            AND review_date &lt;= #{endTime}
476
+        </if>
477
+        GROUP BY difficulty_level
478
+        ORDER BY count DESC
479
+    </select>
480
+
481
+    <!-- 查询查堵-开机人员持证比例(用于扇形图) -->
482
+    <select id="selectCertificateDistribution" resultType="com.sundot.airport.blocked.dto.BlockedCertificateDistributionDTO">
483
+        SELECT 
484
+            u.qualification_level as certificateLevel,
485
+            COUNT(DISTINCT bms.reviewed_user_id) as count,
486
+            ROUND(COUNT(DISTINCT bms.reviewed_user_id) * 100.0 / SUM(COUNT(DISTINCT bms.reviewed_user_id)) OVER(), 2) as percentage
487
+        FROM blocked_miss_check_statistics bms
488
+        INNER JOIN sys_user u ON bms.reviewed_user_id = u.user_id
489
+        WHERE bms.del_flag = '0'
490
+        AND u.del_flag = '0'
491
+        AND u.status = '0'
492
+        AND u.qualification_level IS NOT NULL
493
+        AND u.qualification_level != ''
494
+        <if test="startTime != null and endTime != null">
495
+            AND bms.review_date &gt;= #{startTime}
496
+            AND bms.review_date &lt;= #{endTime}
497
+        </if>
498
+        <if test="brigadeId != null">
499
+            AND bms.brigade_id = #{brigadeId}
500
+        </if>
501
+        <if test="terminalId != null">
502
+            AND bms.terminal_id = #{terminalId}
503
+        </if>
504
+        GROUP BY u.qualification_level
505
+        ORDER BY count DESC
506
+    </select>
507
+
508
+    <!-- 查询大队开机人员证书分布(用于柱状图) -->
509
+    <select id="selectBrigadeCertificateDistribution" resultType="com.sundot.airport.blocked.dto.BlockedBrigadeCertificateDistributionDTO">
510
+        SELECT 
511
+            d.dept_name as brigadeName,
512
+            d.dept_id as brigadeId,
513
+            COUNT(DISTINCT CASE WHEN u.qualification_level = 'LEVEL_ONE' THEN u.user_id END) as levelOneCount,
514
+            COUNT(DISTINCT CASE WHEN u.qualification_level = 'LEVEL_TWO' THEN u.user_id END) as levelTwoCount,
515
+            COUNT(DISTINCT CASE WHEN u.qualification_level = 'LEVEL_THREE' THEN u.user_id END) as levelThreeCount,
516
+            COUNT(DISTINCT CASE WHEN u.qualification_level = 'LEVEL_FOUR' THEN u.user_id END) as levelFourCount,
517
+            COUNT(DISTINCT CASE WHEN u.qualification_level = 'LEVEL_FIVE' THEN u.user_id END) as levelFiveCount,
518
+            COUNT(DISTINCT u.user_id) as totalCount
519
+        FROM sys_user u
520
+        INNER JOIN sys_dept d ON u.dept_id = d.dept_id
521
+        WHERE u.del_flag = '0'
522
+        AND u.status = '0'
523
+        AND u.qualification_level IS NOT NULL
524
+        AND u.qualification_level != ''
525
+        AND d.dept_type = 'BRIGADE'
526
+        <if test="terminalId != null">
527
+            AND d.terminal_id = #{terminalId}
528
+        </if>
529
+        GROUP BY d.dept_id, d.dept_name
530
+        ORDER BY totalCount DESC
531
+    </select>
532
+
533
+</mapper>