53 lines
2.8 KiB
XML
53 lines
2.8 KiB
XML
<?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.czblood.bus.mapper.XkDmzdMapper">
|
|
<update id="updateXkDmzd">
|
|
update xk_dmzd set
|
|
<if test="wordbook_name != null and wordbook_name != ''">wordbook_name=#{wordbook_name},</if>
|
|
<if test="use_sign != null and use_sign != ''">use_sign=#{use_sign},</if>
|
|
<if test="exp1 != null and exp1 != ''">exp1=#{exp1},</if>
|
|
<if test="exp2 != null and exp2 != ''">exp2=#{exp2},</if>
|
|
<if test="exp3 != null and exp3 != ''">exp3=#{exp3},</if>
|
|
<if test="exp4 != null and exp4 != ''">exp4=#{exp4},</if>
|
|
<if test="exp5 != null and exp5 != ''">exp5=#{exp5},</if>
|
|
<if test="remark != null">remark=#{remark},</if>
|
|
wordbook_code=#{wordbook_code}
|
|
where wordbook_sign = #{wordbook_sign} and wordbook_code= #{wordbook_code}
|
|
</update>
|
|
|
|
<delete id="deleteXkDmzd">
|
|
delete from xk_dmzd where wordbook_sign = #{wordbook_sign} and wordbook_code=#{wordbook_code}
|
|
</delete>
|
|
|
|
<select id="queryList" resultType="com.czblood.bus.pojo.XkDmzd">
|
|
select * from xk_dmzd where wordbook_sign=#{wordbook_sign}
|
|
<if test="use_sign != null and use_sign != ''">and use_sign = #{use_sign}</if>
|
|
<if test="wordbook_name != null and wordbook_name != ''">and wordbook_name like '%'+#{wordbook_name}+'%'</if>
|
|
<if test="wordbook_code != null and wordbook_code != ''">and wordbook_code = #{wordbook_code}</if>
|
|
</select>
|
|
|
|
<insert id="insertXkDmzd">
|
|
insert into xk_dmzd(
|
|
<if test="wordbook_name != null and wordbook_name != ''">wordbook_name,</if>
|
|
<if test="use_sign != null and use_sign != ''">use_sign,</if>
|
|
<if test="exp1 != null and exp1 != ''">exp1,</if>
|
|
<if test="exp2 != null and exp2 != ''">exp2,</if>
|
|
<if test="exp3 != null and exp3 != ''">exp3,</if>
|
|
<if test="exp4 != null and exp4 != ''">exp4,</if>
|
|
<if test="exp5 != null and exp5 != ''">exp5,</if>
|
|
<if test="remark != null and remark != ''">remark,</if>
|
|
wordbook_sign,wordbook_code
|
|
)values(
|
|
<if test="wordbook_name != null and wordbook_name != ''">#{wordbook_name},</if>
|
|
<if test="use_sign != null and use_sign != ''">#{use_sign},</if>
|
|
<if test="exp1 != null and exp1 != ''">#{exp1},</if>
|
|
<if test="exp2 != null and exp2 != ''">#{exp2},</if>
|
|
<if test="exp3 != null and exp3 != ''">#{exp3},</if>
|
|
<if test="exp4 != null and exp4 != ''">#{exp4},</if>
|
|
<if test="exp5 != null and exp5 != ''">#{exp5},</if>
|
|
<if test="remark != null and remark != ''">#{remark},</if>
|
|
#{wordbook_sign},#{wordbook_code}
|
|
)
|
|
</insert>
|
|
</mapper> |