feat: 添加编排预计时长显示
1. CompetitionGroupDTO添加estimatedDuration字段 2. ScheduleGroupDetailVO添加estimatedDuration字段 3. SQL查询添加estimated_duration 4. 前端场地视图显示合计时间 Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
This commit is contained in:
@@ -12,6 +12,7 @@
|
||||
g.total_teams AS totalTeams,
|
||||
g.total_participants AS totalParticipants,
|
||||
g.display_order AS displayOrder,
|
||||
g.estimated_duration AS estimatedDuration,
|
||||
d.id AS detailId,
|
||||
d.venue_id AS venueId,
|
||||
d.venue_name AS venueName,
|
||||
|
||||
@@ -77,6 +77,12 @@ public class CompetitionGroupDTO implements Serializable {
|
||||
@Schema(description = "时间段索引")
|
||||
private Integer timeSlotIndex;
|
||||
|
||||
/**
|
||||
* 预计时长(分钟)
|
||||
*/
|
||||
@Schema(description = "预计时长(分钟)")
|
||||
private Integer estimatedDuration;
|
||||
|
||||
/**
|
||||
* 参赛人员列表
|
||||
*/
|
||||
|
||||
@@ -21,6 +21,7 @@ public class ScheduleGroupDetailVO implements Serializable {
|
||||
private Integer totalTeams;
|
||||
private Integer totalParticipants;
|
||||
private Integer displayOrder;
|
||||
private Integer estimatedDuration; // 预计时长(分钟)
|
||||
|
||||
// === 编排明细信息 ===
|
||||
private Long detailId;
|
||||
|
||||
+1
@@ -176,6 +176,7 @@ public class MartialScheduleArrangeServiceImpl implements IMartialScheduleArrang
|
||||
groupData.put("displayOrder", group.getDisplayOrder());
|
||||
groupData.put("totalParticipants", group.getTotalParticipants());
|
||||
groupData.put("totalTeams", group.getTotalTeams());
|
||||
groupData.put("estimatedDuration", group.getEstimatedDuration());
|
||||
|
||||
// 获取该分组的场地时间段详情
|
||||
LambdaQueryWrapper<MartialScheduleDetail> detailWrapper = new LambdaQueryWrapper<>();
|
||||
|
||||
+1
@@ -245,6 +245,7 @@ public class MartialScheduleServiceImpl extends ServiceImpl<MartialScheduleMappe
|
||||
groupDTO.setVenueName(firstDetail.getVenueName());
|
||||
groupDTO.setTimeSlot(firstDetail.getTimeSlot());
|
||||
groupDTO.setTimeSlotIndex(firstDetail.getTimeSlotIndex() != null ? firstDetail.getTimeSlotIndex() : 0);
|
||||
groupDTO.setEstimatedDuration(firstDetail.getEstimatedDuration());
|
||||
|
||||
// 获取参赛者列表
|
||||
List<ParticipantDTO> participantDTOs = groupDetails.stream()
|
||||
|
||||
Reference in New Issue
Block a user