Browse Source

Merge branch 'pt' of dd.tall.wiki:ccsens_wiki/ccsenscloud into pt

tiaosheng
zhizhi wu 5 years ago
parent
commit
7765985c8a
  1. 4
      mt/src/main/java/com/ccsens/mt/api/CompeteScoreController.java
  2. 12
      mt/src/main/java/com/ccsens/mt/bean/po/CompeteProjectConfig.java
  3. 48
      mt/src/main/java/com/ccsens/mt/bean/po/CompeteProjectConfigExample.java
  4. 6
      mt/src/main/java/com/ccsens/mt/bean/vo/CompeteExcelVo.java
  5. 1
      mt/src/main/java/com/ccsens/mt/service/CompeteService.java
  6. 10
      mt/src/main/java/com/ccsens/mt/service/ExcelService.java
  7. 2
      mt/src/main/resources/mapper_dao/CompeteScoreDao.xml
  8. 28
      mt/src/main/resources/mapper_raw/CompeteProjectConfigMapper.xml

4
mt/src/main/java/com/ccsens/mt/api/CompeteScoreController.java

@ -84,7 +84,7 @@ public class CompeteScoreController {
} }
@ApiOperation(value = "项目状态", notes = "") @ApiOperation(value = "项目状态(手机用)", notes = "")
@RequestMapping(value = "/countScore", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"}) @RequestMapping(value = "/countScore", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"})
public JsonResponse<CompeteVo.CountScore> countScore(@ApiParam @Validated @RequestBody QueryDto<CompeteDto.CompeteTime> params) { public JsonResponse<CompeteVo.CountScore> countScore(@ApiParam @Validated @RequestBody QueryDto<CompeteDto.CompeteTime> params) {
log.info("查询比赛项目上的参赛选手列表:{}",params); log.info("查询比赛项目上的参赛选手列表:{}",params);
@ -93,7 +93,7 @@ public class CompeteScoreController {
} }
@ApiOperation(value = "选手排名", notes = "多个信息表关联之后,利用分数排序") @ApiOperation(value = "选手排名(手机用)", notes = "多个信息表关联之后,利用分数排序")
@RequestMapping(value = "/countScoreDetail", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"}) @RequestMapping(value = "/countScoreDetail", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"})
public JsonResponse<ScoreVo.CompeteScore> countScoreDetail(@ApiParam @Validated @RequestBody QueryDto<CompeteDto.ProjectIdAndGroupId> params) { public JsonResponse<ScoreVo.CompeteScore> countScoreDetail(@ApiParam @Validated @RequestBody QueryDto<CompeteDto.ProjectIdAndGroupId> params) {
log.info("查询比赛项目上的参赛选手列表:{}",params); log.info("查询比赛项目上的参赛选手列表:{}",params);

12
mt/src/main/java/com/ccsens/mt/bean/po/CompeteProjectConfig.java

@ -26,7 +26,7 @@ public class CompeteProjectConfig implements Serializable {
private Long videoEndTime; private Long videoEndTime;
private Byte restrict; private Byte videoRestrict;
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
@ -118,12 +118,12 @@ public class CompeteProjectConfig implements Serializable {
this.videoEndTime = videoEndTime; this.videoEndTime = videoEndTime;
} }
public Byte getRestrict() { public Byte getVideoRestrict() {
return restrict; return videoRestrict;
} }
public void setRestrict(Byte restrict) { public void setVideoRestrict(Byte videoRestrict) {
this.restrict = restrict; this.videoRestrict = videoRestrict;
} }
@Override @Override
@ -143,7 +143,7 @@ public class CompeteProjectConfig implements Serializable {
sb.append(", recStatus=").append(recStatus); sb.append(", recStatus=").append(recStatus);
sb.append(", videoStartTime=").append(videoStartTime); sb.append(", videoStartTime=").append(videoStartTime);
sb.append(", videoEndTime=").append(videoEndTime); sb.append(", videoEndTime=").append(videoEndTime);
sb.append(", restrict=").append(restrict); sb.append(", videoRestrict=").append(videoRestrict);
sb.append("]"); sb.append("]");
return sb.toString(); return sb.toString();
} }

48
mt/src/main/java/com/ccsens/mt/bean/po/CompeteProjectConfigExample.java

@ -765,63 +765,63 @@ public class CompeteProjectConfigExample {
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictIsNull() { public Criteria andVideoRestrictIsNull() {
addCriterion("restrict is null"); addCriterion("video_restrict is null");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictIsNotNull() { public Criteria andVideoRestrictIsNotNull() {
addCriterion("restrict is not null"); addCriterion("video_restrict is not null");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictEqualTo(Byte value) { public Criteria andVideoRestrictEqualTo(Byte value) {
addCriterion("restrict =", value, "restrict"); addCriterion("video_restrict =", value, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictNotEqualTo(Byte value) { public Criteria andVideoRestrictNotEqualTo(Byte value) {
addCriterion("restrict <>", value, "restrict"); addCriterion("video_restrict <>", value, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictGreaterThan(Byte value) { public Criteria andVideoRestrictGreaterThan(Byte value) {
addCriterion("restrict >", value, "restrict"); addCriterion("video_restrict >", value, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictGreaterThanOrEqualTo(Byte value) { public Criteria andVideoRestrictGreaterThanOrEqualTo(Byte value) {
addCriterion("restrict >=", value, "restrict"); addCriterion("video_restrict >=", value, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictLessThan(Byte value) { public Criteria andVideoRestrictLessThan(Byte value) {
addCriterion("restrict <", value, "restrict"); addCriterion("video_restrict <", value, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictLessThanOrEqualTo(Byte value) { public Criteria andVideoRestrictLessThanOrEqualTo(Byte value) {
addCriterion("restrict <=", value, "restrict"); addCriterion("video_restrict <=", value, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictIn(List<Byte> values) { public Criteria andVideoRestrictIn(List<Byte> values) {
addCriterion("restrict in", values, "restrict"); addCriterion("video_restrict in", values, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictNotIn(List<Byte> values) { public Criteria andVideoRestrictNotIn(List<Byte> values) {
addCriterion("restrict not in", values, "restrict"); addCriterion("video_restrict not in", values, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictBetween(Byte value1, Byte value2) { public Criteria andVideoRestrictBetween(Byte value1, Byte value2) {
addCriterion("restrict between", value1, value2, "restrict"); addCriterion("video_restrict between", value1, value2, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andRestrictNotBetween(Byte value1, Byte value2) { public Criteria andVideoRestrictNotBetween(Byte value1, Byte value2) {
addCriterion("restrict not between", value1, value2, "restrict"); addCriterion("video_restrict not between", value1, value2, "videoRestrict");
return (Criteria) this; return (Criteria) this;
} }
} }

6
mt/src/main/java/com/ccsens/mt/bean/vo/CompeteExcelVo.java

@ -27,7 +27,7 @@ public class CompeteExcelVo {
public static class TeamOrderPlayerList { public static class TeamOrderPlayerList {
@ApiModelProperty("团队id") @ApiModelProperty("团队id")
private Long teamId; private Long teamId;
@ApiModelProperty("场次") @ApiModelProperty("场次加场地")
private String startOrder; private String startOrder;
@ApiModelProperty("单位名称") @ApiModelProperty("单位名称")
private String companyName; private String companyName;
@ -35,6 +35,10 @@ public class CompeteExcelVo {
private String playerName; private String playerName;
@ApiModelProperty("视频路径") @ApiModelProperty("视频路径")
private String videoUrl; private String videoUrl;
@ApiModelProperty("场次")
private String competeOrder;
@ApiModelProperty("场地")
private String site;
} }
@Data @Data

1
mt/src/main/java/com/ccsens/mt/service/CompeteService.java

@ -72,6 +72,7 @@ public class CompeteService implements ICompeteService {
private CompeteProjectMapper competeProjectMapper; private CompeteProjectMapper competeProjectMapper;
@Resource @Resource
private CompeteProjectPlayerMapper competeProjectPlayerMapper; private CompeteProjectPlayerMapper competeProjectPlayerMapper;
@Resource @Resource
private CompeteGroupMapper competeGroupMapper; private CompeteGroupMapper competeGroupMapper;
@Resource @Resource

10
mt/src/main/java/com/ccsens/mt/service/ExcelService.java

@ -630,6 +630,10 @@ public class ExcelService implements IExcelService {
two6.setValue("参赛人员"); two6.setValue("参赛人员");
PoiUtil.PoiUtilCell two7=new PoiUtil.PoiUtilCell(WebConstant.CELL_NULL, 1, 1); PoiUtil.PoiUtilCell two7=new PoiUtil.PoiUtilCell(WebConstant.CELL_NULL, 1, 1);
two7.setValue("比赛视频路径"); two7.setValue("比赛视频路径");
PoiUtil.PoiUtilCell two8=new PoiUtil.PoiUtilCell(WebConstant.CELL_NULL, 1, 1);
two7.setValue("场次");
PoiUtil.PoiUtilCell two9=new PoiUtil.PoiUtilCell(WebConstant.CELL_NULL, 1, 1);
two7.setValue("场地");
two.add(two1); two.add(two1);
two.add(two2); two.add(two2);
two.add(two3); two.add(two3);
@ -637,6 +641,8 @@ public class ExcelService implements IExcelService {
two.add(two5); two.add(two5);
two.add(two6); two.add(two6);
two.add(two7); two.add(two7);
two.add(two8);
two.add(two9);
biao.add(two); biao.add(two);
for (CompeteExcelVo.Project project : allProjectList) { for (CompeteExcelVo.Project project : allProjectList) {
int j = 0, q = 0;//一个项目得长度 项目循环 int j = 0, q = 0;//一个项目得长度 项目循环
@ -679,6 +685,8 @@ public class ExcelService implements IExcelService {
PoiUtil.PoiUtilCell three5 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getCompanyName(), 1, 1); PoiUtil.PoiUtilCell three5 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getCompanyName(), 1, 1);
PoiUtil.PoiUtilCell three6 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getPlayerName(), 1, 1); PoiUtil.PoiUtilCell three6 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getPlayerName(), 1, 1);
PoiUtil.PoiUtilCell three7 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getVideoUrl(), 1, 1); PoiUtil.PoiUtilCell three7 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getVideoUrl(), 1, 1);
PoiUtil.PoiUtilCell three8 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getCompeteOrder(), 1, 1);
PoiUtil.PoiUtilCell three9 = new PoiUtil.PoiUtilCell(project.getProjectList().get(k).getCompanyNameList().get(m).getSite(), 1, 1);
three.add(three1); three.add(three1);
three.add(three2); three.add(three2);
three.add(three3); three.add(three3);
@ -686,6 +694,8 @@ public class ExcelService implements IExcelService {
three.add(three5); three.add(three5);
three.add(three6); three.add(three6);
three.add(three7); three.add(three7);
three.add(three8);
three.add(three9);
biao.add(three); biao.add(three);
} }
} }

2
mt/src/main/resources/mapper_dao/CompeteScoreDao.xml

@ -932,6 +932,8 @@
<result column="playerName" property="playerName"/> <result column="playerName" property="playerName"/>
<result property="teamId" column="teamId"/> <result property="teamId" column="teamId"/>
<result property="videoUrl" column="videoUrl"/> <result property="videoUrl" column="videoUrl"/>
<result property="competeOrder" column="competeOrder"/>
<result property="site" column="site"/>
</collection> </collection>
</collection> </collection>
</resultMap> </resultMap>

28
mt/src/main/resources/mapper_raw/CompeteProjectConfigMapper.xml

@ -13,7 +13,7 @@
<result column="rec_status" jdbcType="TINYINT" property="recStatus" /> <result column="rec_status" jdbcType="TINYINT" property="recStatus" />
<result column="video_start_time" jdbcType="BIGINT" property="videoStartTime" /> <result column="video_start_time" jdbcType="BIGINT" property="videoStartTime" />
<result column="video_end_time" jdbcType="BIGINT" property="videoEndTime" /> <result column="video_end_time" jdbcType="BIGINT" property="videoEndTime" />
<result column="restrict" jdbcType="TINYINT" property="restrict" /> <result column="video_restrict" jdbcType="TINYINT" property="videoRestrict" />
</resultMap> </resultMap>
<sql id="Example_Where_Clause"> <sql id="Example_Where_Clause">
<where> <where>
@ -75,7 +75,7 @@
</sql> </sql>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
id, project_id, project_duration, site_num, start_time, end_time, created_at, updated_at, id, project_id, project_duration, site_num, start_time, end_time, created_at, updated_at,
rec_status, video_start_time, video_end_time, restrict rec_status, video_start_time, video_end_time, video_restrict
</sql> </sql>
<select id="selectByExample" parameterType="com.ccsens.mt.bean.po.CompeteProjectConfigExample" resultMap="BaseResultMap"> <select id="selectByExample" parameterType="com.ccsens.mt.bean.po.CompeteProjectConfigExample" resultMap="BaseResultMap">
select select
@ -111,12 +111,12 @@
insert into t_compete_project_config (id, project_id, project_duration, insert into t_compete_project_config (id, project_id, project_duration,
site_num, start_time, end_time, site_num, start_time, end_time,
created_at, updated_at, rec_status, created_at, updated_at, rec_status,
video_start_time, video_end_time, restrict video_start_time, video_end_time, video_restrict
) )
values (#{id,jdbcType=BIGINT}, #{projectId,jdbcType=BIGINT}, #{projectDuration,jdbcType=BIGINT}, values (#{id,jdbcType=BIGINT}, #{projectId,jdbcType=BIGINT}, #{projectDuration,jdbcType=BIGINT},
#{siteNum,jdbcType=INTEGER}, #{startTime,jdbcType=BIGINT}, #{endTime,jdbcType=BIGINT}, #{siteNum,jdbcType=INTEGER}, #{startTime,jdbcType=BIGINT}, #{endTime,jdbcType=BIGINT},
#{createdAt,jdbcType=TIMESTAMP}, #{updatedAt,jdbcType=TIMESTAMP}, #{recStatus,jdbcType=TINYINT}, #{createdAt,jdbcType=TIMESTAMP}, #{updatedAt,jdbcType=TIMESTAMP}, #{recStatus,jdbcType=TINYINT},
#{videoStartTime,jdbcType=BIGINT}, #{videoEndTime,jdbcType=BIGINT}, #{restrict,jdbcType=TINYINT} #{videoStartTime,jdbcType=BIGINT}, #{videoEndTime,jdbcType=BIGINT}, #{videoRestrict,jdbcType=TINYINT}
) )
</insert> </insert>
<insert id="insertSelective" parameterType="com.ccsens.mt.bean.po.CompeteProjectConfig"> <insert id="insertSelective" parameterType="com.ccsens.mt.bean.po.CompeteProjectConfig">
@ -155,8 +155,8 @@
<if test="videoEndTime != null"> <if test="videoEndTime != null">
video_end_time, video_end_time,
</if> </if>
<if test="restrict != null"> <if test="videoRestrict != null">
restrict, video_restrict,
</if> </if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
@ -193,8 +193,8 @@
<if test="videoEndTime != null"> <if test="videoEndTime != null">
#{videoEndTime,jdbcType=BIGINT}, #{videoEndTime,jdbcType=BIGINT},
</if> </if>
<if test="restrict != null"> <if test="videoRestrict != null">
#{restrict,jdbcType=TINYINT}, #{videoRestrict,jdbcType=TINYINT},
</if> </if>
</trim> </trim>
</insert> </insert>
@ -240,8 +240,8 @@
<if test="record.videoEndTime != null"> <if test="record.videoEndTime != null">
video_end_time = #{record.videoEndTime,jdbcType=BIGINT}, video_end_time = #{record.videoEndTime,jdbcType=BIGINT},
</if> </if>
<if test="record.restrict != null"> <if test="record.videoRestrict != null">
restrict = #{record.restrict,jdbcType=TINYINT}, video_restrict = #{record.videoRestrict,jdbcType=TINYINT},
</if> </if>
</set> </set>
<if test="_parameter != null"> <if test="_parameter != null">
@ -261,7 +261,7 @@
rec_status = #{record.recStatus,jdbcType=TINYINT}, rec_status = #{record.recStatus,jdbcType=TINYINT},
video_start_time = #{record.videoStartTime,jdbcType=BIGINT}, video_start_time = #{record.videoStartTime,jdbcType=BIGINT},
video_end_time = #{record.videoEndTime,jdbcType=BIGINT}, video_end_time = #{record.videoEndTime,jdbcType=BIGINT},
restrict = #{record.restrict,jdbcType=TINYINT} video_restrict = #{record.videoRestrict,jdbcType=TINYINT}
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
</if> </if>
@ -299,8 +299,8 @@
<if test="videoEndTime != null"> <if test="videoEndTime != null">
video_end_time = #{videoEndTime,jdbcType=BIGINT}, video_end_time = #{videoEndTime,jdbcType=BIGINT},
</if> </if>
<if test="restrict != null"> <if test="videoRestrict != null">
restrict = #{restrict,jdbcType=TINYINT}, video_restrict = #{videoRestrict,jdbcType=TINYINT},
</if> </if>
</set> </set>
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
@ -317,7 +317,7 @@
rec_status = #{recStatus,jdbcType=TINYINT}, rec_status = #{recStatus,jdbcType=TINYINT},
video_start_time = #{videoStartTime,jdbcType=BIGINT}, video_start_time = #{videoStartTime,jdbcType=BIGINT},
video_end_time = #{videoEndTime,jdbcType=BIGINT}, video_end_time = #{videoEndTime,jdbcType=BIGINT},
restrict = #{restrict,jdbcType=TINYINT} video_restrict = #{videoRestrict,jdbcType=TINYINT}
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
</update> </update>
</mapper> </mapper>
Loading…
Cancel
Save