xiangpei
2024-09-03 c7f492c5accca21bdf149148a5be6503552139f1
ycl-server/src/main/resources/mapper/zgyw/CheckTemplateRuleMapper.xml
@@ -3,7 +3,7 @@
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ycl.platform.mapper.CheckTemplateRuleMapper">
    <resultMap type="com.ycl.platform.domain.entity.CheckTemplateRule" id="CheckTemplateRuleResult">
        <result property="id"    column="id" />
        <result property="checkTemplateId"    column="check_template_id"    />
@@ -17,17 +17,17 @@
    <select id="selectCheckTemplateRuleList" resultMap="CheckTemplateRuleResult">
        <include refid="selectCheckTemplateRuleVo"/>
        <where>
        <where>
            <if test="checkTemplateId != null "> and check_template_id = #{checkTemplateId}</if>
            <if test="checkRuleId != null "> and check_rule_id = #{checkRuleId}</if>
        </where>
    </select>
    <select id="selectCheckTemplateRuleById" resultMap="CheckTemplateRuleResult">
        <include refid="selectCheckTemplateRuleVo"/>
        where id = #{id}
    </select>
    <insert id="insertCheckTemplateRule" useGeneratedKeys="true" keyProperty="id">
        insert into t_check_template_rule
        <trim prefix="(" suffix=")" suffixOverrides=",">
@@ -57,7 +57,7 @@
    </delete>
    <delete id="deleteCheckTemplateRuleByIds">
        delete from t_check_template_rule where id in
        delete from t_check_template_rule where id in
        <foreach item="id" collection="array" open="(" separator="," close=")">
            #{id}
        </foreach>
@@ -69,7 +69,7 @@
    <select id="selectListByTemplateId" resultType="com.ycl.platform.domain.entity.CheckTemplateRule">
        select tctr.*,tcr.rule_name as checkRuleName,tcr.rule_index from t_check_template_rule tctr
        left join t_check_rule tcr on tctr.check_rule_id = tcr.id
        where check_template_id = #{checkTemplateId}
        where tctr.check_template_id = #{checkTemplateId}
    </select>
</mapper>
</mapper>