فهرست منبع

feat(tournaments): 添加赛事备注功能

- 在Tournaments实体类中添加remark字段
- 在TournamentsDto数据传输对象中添加remark字段
- 在TournamentsVo视图对象中添加remark字段
- 更新TournamentsMapper.xml中的SQL查询语句,包含remark字段
- 更新TournamentsMapper.xml中的更新和插入语句,支持remark字段操作
- 在TournamentsTemplate模板类中添加remark字段
- 更新TournamentsTemplateMapper.xml中的SQL查询和操作语句,支持remark字段
fugui001 3 روز پیش
والد
کامیت
dde15870fc

+ 2 - 0
ruoyi-modules/ruoyi-system/src/main/java/org/dromara/business/domain/Tournaments.java

@@ -156,4 +156,6 @@ public class Tournaments extends BaseEntity {
     //0-默认不开启延迟看牌,1-开启
     private Integer delayShow;
 
+    private String remark;
+
 }

+ 1 - 0
ruoyi-modules/ruoyi-system/src/main/java/org/dromara/business/domain/TournamentsTemplate.java

@@ -148,5 +148,6 @@ public class TournamentsTemplate extends BaseEntity {
     private Integer rebuy;
     //0-默认不开启延迟看牌,1-开启
     private Integer delayShow;
+    private String remark;
 
 }

+ 2 - 0
ruoyi-modules/ruoyi-system/src/main/java/org/dromara/business/domain/dto/TournamentsDto.java

@@ -115,4 +115,6 @@ public class TournamentsDto {
     private Integer rebuy;
     //0-默认不开启延迟看牌,1-开启
     private Integer delayShow;
+
+    private String remark;
 }

+ 1 - 0
ruoyi-modules/ruoyi-system/src/main/java/org/dromara/business/domain/vo/TournamentsVo.java

@@ -313,4 +313,5 @@ public class TournamentsVo implements Serializable {
     private  String tagNameIds;
     @ExcelProperty(value = "赛事类目")
     private  String categoryNameIds;
+    private String remark;
 }

+ 1 - 0
ruoyi-modules/ruoyi-system/src/main/java/org/dromara/job/business/ScheduleTask.java

@@ -396,6 +396,7 @@ public class ScheduleTask {
             bo.setTagId(tagList);
             bo.setRebuy(tournamentsVo.getRebuy());
             bo.setDelayShow(tournamentsVo.getDelayShow());
+            bo.setRemark(tournamentsVo.getRemark());
             // 调用已有的插入方法
             if (!iTournamentsService.insertByBo(bo)) {
                 log.error("赛事插入失败");

+ 5 - 2
ruoyi-modules/ruoyi-system/src/main/resources/mapper/business/TournamentsMapper.xml

@@ -10,11 +10,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
 
     <select id="selectTournamentsVoList" resultType="org.dromara.business.domain.vo.TournamentsVo">
-        SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,robot_count,is_delete,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show FROM tournaments  ${ew.customSqlSegment}
+        SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,robot_count,is_delete,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show,remark FROM tournaments  ${ew.customSqlSegment}
     </select>
 
     <select id="selectVoByIdInfo" resultType="org.dromara.business.domain.vo.TournamentsVo">
-       SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,robot_count,is_delete,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show FROM tournaments WHERE id =  #{id}
+       SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,robot_count,is_delete,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show,remark FROM tournaments WHERE id =  #{id}
     </select>
 
 
@@ -48,6 +48,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="startBlindLevel != null">start_blind_level = #{startBlindLevel},</if>
             <if test="qualifierValue != null">qualifier_value = #{qualifierValue},</if>
             <if test="rebuy != null">rebuy = #{rebuy},</if>
+            <if test="remark != null">remark = #{remark},</if>
             <if test="delayShow != null">delay_show = #{delayShow}</if>
          </set>
         WHERE id = #{id}
@@ -84,6 +85,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="startBlindLevel != null">start_blind_level,</if>
             <if test="rebuy != null">rebuy,</if>
             <if test="delayShow != null">delay_show,</if>
+            <if test="remark != null">remark,</if>
         </trim>
         VALUES
         <trim prefix="(" suffix=")" suffixOverrides=",">
@@ -114,6 +116,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="startBlindLevel != null">#{startBlindLevel},</if>
             <if test="rebuy != null">#{rebuy},</if>
             <if test="delayShow != null">#{delayShow},</if>
+            <if test="remark != null">#{remark},</if>
         </trim>
     </insert>
 

+ 6 - 2
ruoyi-modules/ruoyi-system/src/main/resources/mapper/business/TournamentsTemplateMapper.xml

@@ -10,11 +10,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
 
     <select id="selectTournamentsVoListTemplate" resultType="org.dromara.business.domain.vo.TournamentsVo">
-        SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,reward_players,total_signup,robot_count,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show FROM tournaments_template  ${ew.customSqlSegment}
+        SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,reward_players,total_signup,robot_count,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show,remark FROM tournaments_template  ${ew.customSqlSegment}
     </select>
 
     <select id="selectVoByIdInfoTemplate" resultType="org.dromara.business.domain.vo.TournamentsVo">
-       SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,reward_players,total_signup,robot_count,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show FROM tournaments_template WHERE id =  #{id}
+       SELECT id, name, start_time, end_time,game_type, starting_chips, level_duration, late_registration_level, max_players, status, created_at, updated_at,sign_time,competition_icon,tournaments_bi_id,reward_players,total_signup,robot_count,delay_card_time,delay_card_num,action_time,competition_bg,min_players,game_variant,target_tournament_id,qualifier_value,qualifier_type,start_blind_level,rebuy,delay_show,remark FROM tournaments_template WHERE id =  #{id}
     </select>
 
 
@@ -48,6 +48,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="startBlindLevel != null">start_blind_level = #{startBlindLevel},</if>
             <if test="qualifierValue != null">qualifier_value = #{qualifierValue},</if>
             <if test="rebuy != null">rebuy = #{rebuy},</if>
+            <if test="remark != null">remark = #{remark},</if>
             <if test="delayShow != null">delay_show = #{delayShow}</if>
         </set>
         WHERE id = #{id}
@@ -83,6 +84,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="startBlindLevel != null">start_blind_level,</if>
             <if test="rebuy != null">rebuy,</if>
             <if test="delayShow != null">delay_show,</if>
+            <if test="remark != null">remark,</if>
         </trim>
         VALUES
         <trim prefix="(" suffix=")" suffixOverrides=",">
@@ -111,7 +113,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="qualifierValue != null">#{qualifierValue},</if>
             <if test="startBlindLevel != null">#{startBlindLevel},</if>
             <if test="rebuy != null">#{rebuy},</if>
+            <if test="remark != null">remark = #{remark},</if>
             <if test="delayShow != null">#{delayShow},</if>
+            <if test="remark != null">#{remark},</if>
         </trim>
     </insert>