123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188 |
- <?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.xinxin.topro.inpnurseservice.mysqlmapper.DicCatheterMapper" >
- <resultMap id="BaseResultMap" type="com.xinxin.topro.inpnurseservice.mysqlmodel.DicCatheter" >
- <id column="DC_ID" property="dcId" jdbcType="INTEGER" />
- <result column="HI_ID" property="hiId" jdbcType="INTEGER" />
- <result column="DC_Catheter_Name" property="dcCatheterName" jdbcType="VARCHAR" />
- <result column="DC_PinyinCode" property="dcPinyincode" jdbcType="VARCHAR" />
- <result column="DC_WubiCode" property="dcWubicode" jdbcType="VARCHAR" />
- <result column="DC_OtherCode" property="dcOthercode" jdbcType="VARCHAR" />
- <result column="DC_Sort" property="dcSort" jdbcType="INTEGER" />
- <result column="DC_Material" property="dcMaterial" jdbcType="VARCHAR" />
- <result column="DC_Way" property="dcWay" jdbcType="VARCHAR" />
- <result column="DC_Category" property="dcCategory" jdbcType="VARCHAR" />
- <result column="DC_Valid_Time" property="dcValidTime" jdbcType="INTEGER" />
- <result column="DC_IsDel" property="dcIsdel" jdbcType="INTEGER" />
- <result column="DC_IsVein" property="dcIsVein" jdbcType="INTEGER" />
- <result column="DC_Crisis" property="dcCrisis" jdbcType="INTEGER" />
- </resultMap>
- <sql id="Base_Column_List" >
- DC_ID, HI_ID, DC_Catheter_Name, DC_PinyinCode, DC_WubiCode, DC_OtherCode,
- DC_Sort, DC_Material, DC_Way, DC_Category, DC_Valid_Time, DC_IsDel, DC_IsVein, DC_Crisis
- </sql>
- <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
- select
- <include refid="Base_Column_List" />
- from dic_catheter
- where DC_IsDel = 0 and DC_ID = #{dcId,jdbcType=INTEGER}
- </select>
- <select id="selectIds" resultMap="BaseResultMap" parameterType="List" >
- select
- <include refid="Base_Column_List" />
- from dic_catheter
- where DC_IsDel = 0 and DC_ID in
- <foreach collection="list" item="item" index="index" separator="," open="(" close=")">
- #{item,jdbcType=INTEGER}
- </foreach>
- order by DC_Sort desc
- </select>
- <select id="selectAll" resultMap="BaseResultMap">
- select
- <include refid="Base_Column_List" />
- from dic_catheter
- where DC_IsDel = 0 and HI_ID = #{hiId,jdbcType=INTEGER}
- order by DC_Sort desc
- </select>
- <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
- delete from dic_catheter
- where DC_ID = #{dcId,jdbcType=INTEGER}
- </delete>
- <insert id="insertSelective" parameterType="com.xinxin.topro.inpnurseservice.mysqlmodel.DicCatheter" >
- insert into dic_catheter
- <trim prefix="(" suffix=")" suffixOverrides="," >
- <if test="dcId != null" >
- DC_ID,
- </if>
- <if test="hiId != null" >
- HI_ID,
- </if>
- <if test="dcCatheterName != null" >
- DC_Catheter_Name,
- </if>
- <if test="dcPinyincode != null" >
- DC_PinyinCode,
- </if>
- <if test="dcWubicode != null" >
- DC_WubiCode,
- </if>
- <if test="dcOthercode != null" >
- DC_OtherCode,
- </if>
- <if test="dcSort != null" >
- DC_Sort,
- </if>
- <if test="dcMaterial != null" >
- DC_Material,
- </if>
- <if test="dcWay != null" >
- DC_Way,
- </if>
- <if test="dcCategory != null" >
- DC_Category,
- </if>
- <if test="dcValidTime != null" >
- DC_Valid_Time,
- </if>
- <if test="dcIsdel != null" >
- DC_IsDel,
- </if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides="," >
- <if test="dcId != null" >
- #{dcId,jdbcType=INTEGER},
- </if>
- <if test="hiId != null" >
- #{hiId,jdbcType=INTEGER},
- </if>
- <if test="dcCatheterName != null" >
- #{dcCatheterName,jdbcType=VARCHAR},
- </if>
- <if test="dcPinyincode != null" >
- #{dcPinyincode,jdbcType=VARCHAR},
- </if>
- <if test="dcWubicode != null" >
- #{dcWubicode,jdbcType=VARCHAR},
- </if>
- <if test="dcOthercode != null" >
- #{dcOthercode,jdbcType=VARCHAR},
- </if>
- <if test="dcSort != null" >
- #{dcSort,jdbcType=INTEGER},
- </if>
- <if test="dcMaterial != null" >
- #{dcMaterial,jdbcType=VARCHAR},
- </if>
- <if test="dcWay != null" >
- #{dcWay,jdbcType=VARCHAR},
- </if>
- <if test="dcCategory != null" >
- #{dcCategory,jdbcType=VARCHAR},
- </if>
- <if test="dcValidTime != null" >
- #{dcValidTime,jdbcType=INTEGER},
- </if>
- <if test="dcIsdel != null" >
- #{dcIsdel,jdbcType=INTEGER},
- </if>
- </trim>
- </insert>
- <update id="updateByPrimaryKeySelective" parameterType="com.xinxin.topro.inpnurseservice.mysqlmodel.DicCatheter" >
- update dic_catheter
- <set >
- <if test="hiId != null" >
- HI_ID = #{hiId,jdbcType=INTEGER},
- </if>
- <if test="dcCatheterName != null" >
- DC_Catheter_Name = #{dcCatheterName,jdbcType=VARCHAR},
- </if>
- <if test="dcPinyincode != null" >
- DC_PinyinCode = #{dcPinyincode,jdbcType=VARCHAR},
- </if>
- <if test="dcWubicode != null" >
- DC_WubiCode = #{dcWubicode,jdbcType=VARCHAR},
- </if>
- <if test="dcOthercode != null" >
- DC_OtherCode = #{dcOthercode,jdbcType=VARCHAR},
- </if>
- <if test="dcSort != null" >
- DC_Sort = #{dcSort,jdbcType=INTEGER},
- </if>
- <if test="dcMaterial != null" >
- DC_Material = #{dcMaterial,jdbcType=VARCHAR},
- </if>
- <if test="dcWay != null" >
- DC_Way = #{dcWay,jdbcType=VARCHAR},
- </if>
- <if test="dcCategory != null" >
- DC_Category = #{dcCategory,jdbcType=VARCHAR},
- </if>
- <if test="dcValidTime != null" >
- DC_Valid_Time = #{dcValidTime,jdbcType=INTEGER},
- </if>
- <if test="dcIsdel != null" >
- DC_IsDel = #{dcIsdel,jdbcType=INTEGER},
- </if>
- </set>
- where DC_ID = #{dcId,jdbcType=INTEGER}
- </update>
- <select id="selectListByHiId" resultMap="BaseResultMap">
- select
- <include refid="Base_Column_List" />
- from dic_catheter
- where DC_IsDel = 0
- and HI_ID = #{hiId,jdbcType=INTEGER}
- <if test="dcIsVein != null">
- and DC_IsVein = #{dcIsVein,jdbcType=INTEGER}
- </if>
- order by DC_Sort
- </select>
- </mapper>
|