|
|
@@ -0,0 +1,165 @@
|
|
|
+<?xml version="1.0" encoding="UTF-8" ?>
|
|
|
+<!DOCTYPE mapper
|
|
|
+ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
+ "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
+<mapper namespace="com.jjt.biz.mapper.HlScoreDetailMapper">
|
|
|
+
|
|
|
+ <resultMap type="HlScoreDetail" id="HlScoreDetailResult">
|
|
|
+ <result property="hlScoreDetailId" column="HL_SCORE_DETAIL_ID"/>
|
|
|
+ <result property="hlScoreId" column="HL_SCORE_ID"/>
|
|
|
+ <result property="hlType" column="HL_TYPE"/>
|
|
|
+ <result property="hlCode" column="HL_CODE"/>
|
|
|
+ <result property="hlScore" column="HL_SCORE"/>
|
|
|
+ <result property="hlValue" column="HL_VALUE"/>
|
|
|
+ <result property="createBy" column="CREATE_BY"/>
|
|
|
+ <result property="createTime" column="CREATE_TIME"/>
|
|
|
+ <result property="updateBy" column="UPDATE_BY"/>
|
|
|
+ <result property="updateTime" column="UPDATE_TIME"/>
|
|
|
+ <result property="remark" column="REMARK"/>
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+ <sql id="selectHlScoreDetailVo">
|
|
|
+ select HL_SCORE_DETAIL_ID, HL_SCORE_ID, HL_TYPE, HL_CODE, HL_SCORE, HL_VALUE, CREATE_BY, CREATE_TIME, UPDATE_BY, UPDATE_TIME, REMARK
|
|
|
+ from hl_score_detail
|
|
|
+ </sql>
|
|
|
+
|
|
|
+ <select id="selectHlScoreDetailList" parameterType="HlScoreDetail" resultMap="HlScoreDetailResult">
|
|
|
+ <include refid="selectHlScoreDetailVo"/>
|
|
|
+ <where>
|
|
|
+ <if test="hlScoreId != null ">
|
|
|
+ and HL_SCORE_ID = #{hlScoreId}
|
|
|
+ </if>
|
|
|
+ <if test="hlType != null and hlType != ''">
|
|
|
+ and HL_TYPE = #{hlType}
|
|
|
+ </if>
|
|
|
+ <if test="hlCode != null and hlCode != ''">
|
|
|
+ and HL_CODE = #{hlCode}
|
|
|
+ </if>
|
|
|
+ <if test="hlScore != null ">
|
|
|
+ and HL_SCORE = #{hlScore}
|
|
|
+ </if>
|
|
|
+ <if test="hlValue != null and hlValue != ''">
|
|
|
+ and HL_VALUE = #{hlValue}
|
|
|
+ </if>
|
|
|
+ <if test="createBy != null and createBy != ''">
|
|
|
+ and CREATE_BY = #{createBy}
|
|
|
+ </if>
|
|
|
+ <if test="createTime != null ">
|
|
|
+ and CREATE_TIME = #{createTime}
|
|
|
+ </if>
|
|
|
+ <if test="updateBy != null and updateBy != ''">
|
|
|
+ and UPDATE_BY = #{updateBy}
|
|
|
+ </if>
|
|
|
+ <if test="updateTime != null ">
|
|
|
+ and UPDATE_TIME = #{updateTime}
|
|
|
+ </if>
|
|
|
+ <if test="remark != null and remark != ''">
|
|
|
+ and REMARK = #{remark}
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="selectHlScoreDetailByHlScoreDetailId" parameterType="Long"
|
|
|
+ resultMap="HlScoreDetailResult">
|
|
|
+ <include refid="selectHlScoreDetailVo"/>
|
|
|
+ where HL_SCORE_DETAIL_ID = #{hlScoreDetailId}
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <insert id="insertHlScoreDetail" parameterType="HlScoreDetail" useGeneratedKeys="true"
|
|
|
+ keyProperty="hlScoreDetailId">
|
|
|
+ insert into hl_score_detail
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="hlScoreId != null">HL_SCORE_ID,
|
|
|
+ </if>
|
|
|
+ <if test="hlType != null">HL_TYPE,
|
|
|
+ </if>
|
|
|
+ <if test="hlCode != null">HL_CODE,
|
|
|
+ </if>
|
|
|
+ <if test="hlScore != null">HL_SCORE,
|
|
|
+ </if>
|
|
|
+ <if test="hlValue != null">HL_VALUE,
|
|
|
+ </if>
|
|
|
+ <if test="createBy != null">CREATE_BY,
|
|
|
+ </if>
|
|
|
+ <if test="createTime != null">CREATE_TIME,
|
|
|
+ </if>
|
|
|
+ <if test="updateBy != null">UPDATE_BY,
|
|
|
+ </if>
|
|
|
+ <if test="updateTime != null">UPDATE_TIME,
|
|
|
+ </if>
|
|
|
+ <if test="remark != null">REMARK,
|
|
|
+ </if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="hlScoreId != null">#{hlScoreId},
|
|
|
+ </if>
|
|
|
+ <if test="hlType != null">#{hlType},
|
|
|
+ </if>
|
|
|
+ <if test="hlCode != null">#{hlCode},
|
|
|
+ </if>
|
|
|
+ <if test="hlScore != null">#{hlScore},
|
|
|
+ </if>
|
|
|
+ <if test="hlValue != null">#{hlValue},
|
|
|
+ </if>
|
|
|
+ <if test="createBy != null">#{createBy},
|
|
|
+ </if>
|
|
|
+ <if test="createTime != null">#{createTime},
|
|
|
+ </if>
|
|
|
+ <if test="updateBy != null">#{updateBy},
|
|
|
+ </if>
|
|
|
+ <if test="updateTime != null">#{updateTime},
|
|
|
+ </if>
|
|
|
+ <if test="remark != null">#{remark},
|
|
|
+ </if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <update id="updateHlScoreDetail" parameterType="HlScoreDetail">
|
|
|
+ update hl_score_detail
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="hlScoreId != null">HL_SCORE_ID =
|
|
|
+ #{hlScoreId},
|
|
|
+ </if>
|
|
|
+ <if test="hlType != null">HL_TYPE =
|
|
|
+ #{hlType},
|
|
|
+ </if>
|
|
|
+ <if test="hlCode != null">HL_CODE =
|
|
|
+ #{hlCode},
|
|
|
+ </if>
|
|
|
+ <if test="hlScore != null">HL_SCORE =
|
|
|
+ #{hlScore},
|
|
|
+ </if>
|
|
|
+ <if test="hlValue != null">HL_VALUE =
|
|
|
+ #{hlValue},
|
|
|
+ </if>
|
|
|
+ <if test="createBy != null">CREATE_BY =
|
|
|
+ #{createBy},
|
|
|
+ </if>
|
|
|
+ <if test="createTime != null">CREATE_TIME =
|
|
|
+ #{createTime},
|
|
|
+ </if>
|
|
|
+ <if test="updateBy != null">UPDATE_BY =
|
|
|
+ #{updateBy},
|
|
|
+ </if>
|
|
|
+ <if test="updateTime != null">UPDATE_TIME =
|
|
|
+ #{updateTime},
|
|
|
+ </if>
|
|
|
+ <if test="remark != null">REMARK =
|
|
|
+ #{remark},
|
|
|
+ </if>
|
|
|
+ </trim>
|
|
|
+ where HL_SCORE_DETAIL_ID = #{hlScoreDetailId}
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <delete id="deleteHlScoreDetailByHlScoreDetailId" parameterType="Long">
|
|
|
+ delete
|
|
|
+ from hl_score_detail where HL_SCORE_DETAIL_ID = #{hlScoreDetailId}
|
|
|
+ </delete>
|
|
|
+
|
|
|
+ <delete id="deleteHlScoreDetailByHlScoreDetailIds" parameterType="String">
|
|
|
+ delete from hl_score_detail where HL_SCORE_DETAIL_ID in
|
|
|
+ <foreach item="hlScoreDetailId" collection="array" open="(" separator="," close=")">
|
|
|
+ #{hlScoreDetailId}
|
|
|
+ </foreach>
|
|
|
+ </delete>
|
|
|
+</mapper>
|