Browse Source

11-23-4

tiaosheng
Lihong@123456 5 years ago
parent
commit
823dcb129a
  1. 1
      mt/src/main/java/com/ccsens/mt/api/ExcelController.java
  2. 24
      mt/src/main/java/com/ccsens/mt/bean/po/CompeteCountScore.java
  3. 120
      mt/src/main/java/com/ccsens/mt/bean/po/CompeteCountScoreExample.java
  4. 5
      mt/src/main/java/com/ccsens/mt/persist/mapper/CompeteCountScoreMapper.java
  5. 1
      mt/src/main/java/com/ccsens/mt/service/CompeteScoreService.java
  6. 2
      mt/src/main/resources/logback-spring.xml
  7. 50
      mt/src/main/resources/mapper_raw/CompeteCountScoreMapper.xml

1
mt/src/main/java/com/ccsens/mt/api/ExcelController.java

@ -75,7 +75,6 @@ public class ExcelController {
return JsonResponse.newInstance().ok(path);
}
@MustLogin
@ApiOperation(value = "大赛参赛队伍信息表", notes = "")
@RequestMapping(value = "/competitionTeamInformationTable", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"})

24
mt/src/main/java/com/ccsens/mt/bean/po/CompeteCountScore.java

@ -4,7 +4,9 @@ import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
public class CompeteCountScore extends CompeteCountScoreKey implements Serializable {
public class CompeteCountScore implements Serializable {
private Long id;
private Long competeTimeId;
private Long projectId;
@ -17,6 +19,8 @@ public class CompeteCountScore extends CompeteCountScoreKey implements Serializa
private BigDecimal judgmentBScore2;
private Integer shouldTimes;
private Integer deductTimes;
private String deductCause;
@ -31,6 +35,14 @@ public class CompeteCountScore extends CompeteCountScoreKey implements Serializa
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public Long getCompeteTimeId() {
return competeTimeId;
}
@ -79,6 +91,14 @@ public class CompeteCountScore extends CompeteCountScoreKey implements Serializa
this.judgmentBScore2 = judgmentBScore2;
}
public Integer getShouldTimes() {
return shouldTimes;
}
public void setShouldTimes(Integer shouldTimes) {
this.shouldTimes = shouldTimes;
}
public Integer getDeductTimes() {
return deductTimes;
}
@ -133,12 +153,14 @@ public class CompeteCountScore extends CompeteCountScoreKey implements Serializa
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", competeTimeId=").append(competeTimeId);
sb.append(", projectId=").append(projectId);
sb.append(", siteOrderId=").append(siteOrderId);
sb.append(", chiefJudgmentScore=").append(chiefJudgmentScore);
sb.append(", judgmentAScore=").append(judgmentAScore);
sb.append(", judgmentBScore2=").append(judgmentBScore2);
sb.append(", shouldTimes=").append(shouldTimes);
sb.append(", deductTimes=").append(deductTimes);
sb.append(", deductCause=").append(deductCause);
sb.append(", finalScore=").append(finalScore);

120
mt/src/main/java/com/ccsens/mt/bean/po/CompeteCountScoreExample.java

@ -166,66 +166,6 @@ public class CompeteCountScoreExample {
return (Criteria) this;
}
public Criteria andShouldTimesIsNull() {
addCriterion("should_times is null");
return (Criteria) this;
}
public Criteria andShouldTimesIsNotNull() {
addCriterion("should_times is not null");
return (Criteria) this;
}
public Criteria andShouldTimesEqualTo(Integer value) {
addCriterion("should_times =", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesNotEqualTo(Integer value) {
addCriterion("should_times <>", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesGreaterThan(Integer value) {
addCriterion("should_times >", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesGreaterThanOrEqualTo(Integer value) {
addCriterion("should_times >=", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesLessThan(Integer value) {
addCriterion("should_times <", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesLessThanOrEqualTo(Integer value) {
addCriterion("should_times <=", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesIn(List<Integer> values) {
addCriterion("should_times in", values, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesNotIn(List<Integer> values) {
addCriterion("should_times not in", values, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesBetween(Integer value1, Integer value2) {
addCriterion("should_times between", value1, value2, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesNotBetween(Integer value1, Integer value2) {
addCriterion("should_times not between", value1, value2, "shouldTimes");
return (Criteria) this;
}
public Criteria andCompeteTimeIdIsNull() {
addCriterion("compete_time_id is null");
return (Criteria) this;
@ -586,6 +526,66 @@ public class CompeteCountScoreExample {
return (Criteria) this;
}
public Criteria andShouldTimesIsNull() {
addCriterion("should_times is null");
return (Criteria) this;
}
public Criteria andShouldTimesIsNotNull() {
addCriterion("should_times is not null");
return (Criteria) this;
}
public Criteria andShouldTimesEqualTo(Integer value) {
addCriterion("should_times =", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesNotEqualTo(Integer value) {
addCriterion("should_times <>", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesGreaterThan(Integer value) {
addCriterion("should_times >", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesGreaterThanOrEqualTo(Integer value) {
addCriterion("should_times >=", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesLessThan(Integer value) {
addCriterion("should_times <", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesLessThanOrEqualTo(Integer value) {
addCriterion("should_times <=", value, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesIn(List<Integer> values) {
addCriterion("should_times in", values, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesNotIn(List<Integer> values) {
addCriterion("should_times not in", values, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesBetween(Integer value1, Integer value2) {
addCriterion("should_times between", value1, value2, "shouldTimes");
return (Criteria) this;
}
public Criteria andShouldTimesNotBetween(Integer value1, Integer value2) {
addCriterion("should_times not between", value1, value2, "shouldTimes");
return (Criteria) this;
}
public Criteria andDeductTimesIsNull() {
addCriterion("deduct_times is null");
return (Criteria) this;

5
mt/src/main/java/com/ccsens/mt/persist/mapper/CompeteCountScoreMapper.java

@ -2,7 +2,6 @@ package com.ccsens.mt.persist.mapper;
import com.ccsens.mt.bean.po.CompeteCountScore;
import com.ccsens.mt.bean.po.CompeteCountScoreExample;
import com.ccsens.mt.bean.po.CompeteCountScoreKey;
import java.util.List;
import org.apache.ibatis.annotations.Param;
@ -11,7 +10,7 @@ public interface CompeteCountScoreMapper {
int deleteByExample(CompeteCountScoreExample example);
int deleteByPrimaryKey(CompeteCountScoreKey key);
int deleteByPrimaryKey(Long id);
int insert(CompeteCountScore record);
@ -19,7 +18,7 @@ public interface CompeteCountScoreMapper {
List<CompeteCountScore> selectByExample(CompeteCountScoreExample example);
CompeteCountScore selectByPrimaryKey(CompeteCountScoreKey key);
CompeteCountScore selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") CompeteCountScore record, @Param("example") CompeteCountScoreExample example);

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

@ -25,7 +25,6 @@ public class CompeteScoreService implements ICompeteScoreService{
private CompeteCountScoreMapper competeCountScoreMapper;
@Resource
private Snowflake snowflake;
@Override
public void submitScore(CompeteDto.SubmitScore param) {
//查找该场次已经有的分数

2
mt/src/main/resources/logback-spring.xml

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<!-- 日志级别从低到高分为TRACE < DEBUG < INFO < WARN < ERROR < FATAL,如果设置为WARN,则低于WARN的信息都不会输出 -->
<!-- scan:当此属性设置为true时,配置文件如果发生改变,将会被重新加载,默认值为true -->
<!-- scanPeriod:设置监测配置文件是否有修改的时间间隔,如果没有给出时间单位,默认单位是毫秒。当scan为true时,此属性生效。默认的时间间隔为1分钟。 -->

50
mt/src/main/resources/mapper_raw/CompeteCountScoreMapper.xml

@ -3,13 +3,13 @@
<mapper namespace="com.ccsens.mt.persist.mapper.CompeteCountScoreMapper">
<resultMap id="BaseResultMap" type="com.ccsens.mt.bean.po.CompeteCountScore">
<id column="id" jdbcType="BIGINT" property="id" />
<id column="should_times" jdbcType="INTEGER" property="shouldTimes" />
<result column="compete_time_id" jdbcType="BIGINT" property="competeTimeId" />
<result column="project_id" jdbcType="BIGINT" property="projectId" />
<result column="site_order_id" jdbcType="BIGINT" property="siteOrderId" />
<result column="chief_judgment_score" jdbcType="DECIMAL" property="chiefJudgmentScore" />
<result column="judgment_a_score" jdbcType="DECIMAL" property="judgmentAScore" />
<result column="judgment_b_score2" jdbcType="DECIMAL" property="judgmentBScore2" />
<result column="should_times" jdbcType="INTEGER" property="shouldTimes" />
<result column="deduct_times" jdbcType="INTEGER" property="deductTimes" />
<result column="deduct_cause" jdbcType="VARCHAR" property="deductCause" />
<result column="final_score" jdbcType="DECIMAL" property="finalScore" />
@ -76,8 +76,8 @@
</where>
</sql>
<sql id="Base_Column_List">
id, should_times, compete_time_id, project_id, site_order_id, chief_judgment_score,
judgment_a_score, judgment_b_score2, deduct_times, deduct_cause, final_score, created_at,
id, compete_time_id, project_id, site_order_id, chief_judgment_score, judgment_a_score,
judgment_b_score2, should_times, deduct_times, deduct_cause, final_score, created_at,
updated_at, rec_status
</sql>
<select id="selectByExample" parameterType="com.ccsens.mt.bean.po.CompeteCountScoreExample" resultMap="BaseResultMap">
@ -94,17 +94,15 @@
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="com.ccsens.mt.bean.po.CompeteCountScoreKey" resultMap="BaseResultMap">
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_compete_count_score
where id = #{id,jdbcType=BIGINT}
and should_times = #{shouldTimes,jdbcType=INTEGER}
</select>
<delete id="deleteByPrimaryKey" parameterType="com.ccsens.mt.bean.po.CompeteCountScoreKey">
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from t_compete_count_score
where id = #{id,jdbcType=BIGINT}
and should_times = #{shouldTimes,jdbcType=INTEGER}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.mt.bean.po.CompeteCountScoreExample">
delete from t_compete_count_score
@ -113,14 +111,14 @@
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.mt.bean.po.CompeteCountScore">
insert into t_compete_count_score (id, should_times, compete_time_id,
project_id, site_order_id, chief_judgment_score,
judgment_a_score, judgment_b_score2, deduct_times,
insert into t_compete_count_score (id, compete_time_id, project_id,
site_order_id, chief_judgment_score, judgment_a_score,
judgment_b_score2, should_times, deduct_times,
deduct_cause, final_score, created_at,
updated_at, rec_status)
values (#{id,jdbcType=BIGINT}, #{shouldTimes,jdbcType=INTEGER}, #{competeTimeId,jdbcType=BIGINT},
#{projectId,jdbcType=BIGINT}, #{siteOrderId,jdbcType=BIGINT}, #{chiefJudgmentScore,jdbcType=DECIMAL},
#{judgmentAScore,jdbcType=DECIMAL}, #{judgmentBScore2,jdbcType=DECIMAL}, #{deductTimes,jdbcType=INTEGER},
values (#{id,jdbcType=BIGINT}, #{competeTimeId,jdbcType=BIGINT}, #{projectId,jdbcType=BIGINT},
#{siteOrderId,jdbcType=BIGINT}, #{chiefJudgmentScore,jdbcType=DECIMAL}, #{judgmentAScore,jdbcType=DECIMAL},
#{judgmentBScore2,jdbcType=DECIMAL}, #{shouldTimes,jdbcType=INTEGER}, #{deductTimes,jdbcType=INTEGER},
#{deductCause,jdbcType=VARCHAR}, #{finalScore,jdbcType=DECIMAL}, #{createdAt,jdbcType=TIMESTAMP},
#{updatedAt,jdbcType=TIMESTAMP}, #{recStatus,jdbcType=TINYINT})
</insert>
@ -130,9 +128,6 @@
<if test="id != null">
id,
</if>
<if test="shouldTimes != null">
should_times,
</if>
<if test="competeTimeId != null">
compete_time_id,
</if>
@ -151,6 +146,9 @@
<if test="judgmentBScore2 != null">
judgment_b_score2,
</if>
<if test="shouldTimes != null">
should_times,
</if>
<if test="deductTimes != null">
deduct_times,
</if>
@ -174,9 +172,6 @@
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="shouldTimes != null">
#{shouldTimes,jdbcType=INTEGER},
</if>
<if test="competeTimeId != null">
#{competeTimeId,jdbcType=BIGINT},
</if>
@ -195,6 +190,9 @@
<if test="judgmentBScore2 != null">
#{judgmentBScore2,jdbcType=DECIMAL},
</if>
<if test="shouldTimes != null">
#{shouldTimes,jdbcType=INTEGER},
</if>
<if test="deductTimes != null">
#{deductTimes,jdbcType=INTEGER},
</if>
@ -227,9 +225,6 @@
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.shouldTimes != null">
should_times = #{record.shouldTimes,jdbcType=INTEGER},
</if>
<if test="record.competeTimeId != null">
compete_time_id = #{record.competeTimeId,jdbcType=BIGINT},
</if>
@ -248,6 +243,9 @@
<if test="record.judgmentBScore2 != null">
judgment_b_score2 = #{record.judgmentBScore2,jdbcType=DECIMAL},
</if>
<if test="record.shouldTimes != null">
should_times = #{record.shouldTimes,jdbcType=INTEGER},
</if>
<if test="record.deductTimes != null">
deduct_times = #{record.deductTimes,jdbcType=INTEGER},
</if>
@ -274,13 +272,13 @@
<update id="updateByExample" parameterType="map">
update t_compete_count_score
set id = #{record.id,jdbcType=BIGINT},
should_times = #{record.shouldTimes,jdbcType=INTEGER},
compete_time_id = #{record.competeTimeId,jdbcType=BIGINT},
project_id = #{record.projectId,jdbcType=BIGINT},
site_order_id = #{record.siteOrderId,jdbcType=BIGINT},
chief_judgment_score = #{record.chiefJudgmentScore,jdbcType=DECIMAL},
judgment_a_score = #{record.judgmentAScore,jdbcType=DECIMAL},
judgment_b_score2 = #{record.judgmentBScore2,jdbcType=DECIMAL},
should_times = #{record.shouldTimes,jdbcType=INTEGER},
deduct_times = #{record.deductTimes,jdbcType=INTEGER},
deduct_cause = #{record.deductCause,jdbcType=VARCHAR},
final_score = #{record.finalScore,jdbcType=DECIMAL},
@ -312,6 +310,9 @@
<if test="judgmentBScore2 != null">
judgment_b_score2 = #{judgmentBScore2,jdbcType=DECIMAL},
</if>
<if test="shouldTimes != null">
should_times = #{shouldTimes,jdbcType=INTEGER},
</if>
<if test="deductTimes != null">
deduct_times = #{deductTimes,jdbcType=INTEGER},
</if>
@ -332,7 +333,6 @@
</if>
</set>
where id = #{id,jdbcType=BIGINT}
and should_times = #{shouldTimes,jdbcType=INTEGER}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.mt.bean.po.CompeteCountScore">
update t_compete_count_score
@ -342,6 +342,7 @@
chief_judgment_score = #{chiefJudgmentScore,jdbcType=DECIMAL},
judgment_a_score = #{judgmentAScore,jdbcType=DECIMAL},
judgment_b_score2 = #{judgmentBScore2,jdbcType=DECIMAL},
should_times = #{shouldTimes,jdbcType=INTEGER},
deduct_times = #{deductTimes,jdbcType=INTEGER},
deduct_cause = #{deductCause,jdbcType=VARCHAR},
final_score = #{finalScore,jdbcType=DECIMAL},
@ -349,6 +350,5 @@
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
rec_status = #{recStatus,jdbcType=TINYINT}
where id = #{id,jdbcType=BIGINT}
and should_times = #{shouldTimes,jdbcType=INTEGER}
</update>
</mapper>
Loading…
Cancel
Save