123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174 |
- <?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.sysservice.dao.mysqlmapper.DicIoPropertyMapper" >
- <resultMap id="BaseResultMap" type="com.xinxin.topro.sysservice.dao.mysqlmodel.SysDicIoProperty" >
- <id column="DIP_ID" property="dipId" jdbcType="INTEGER" />
- <result column="DIO_ID" property="dioId" jdbcType="INTEGER" />
- <result column="DIP_PropCode" property="dipPropcode" jdbcType="VARCHAR" />
- <result column="DIP_PropName" property="dipPropname" jdbcType="VARCHAR" />
- <result column="DIP_Operation_Time" property="dipOperationTime" jdbcType="TIMESTAMP" />
- <result column="DIP_Operator" property="dipOperator" jdbcType="VARCHAR" />
- <result column="DIP_SupID" property="dipSupid" jdbcType="INTEGER" />
- <result column="DIP_IsDel" property="dipIsdel" jdbcType="INTEGER" />
- <result column="DIP_Sort" property="dipSort" jdbcType="INTEGER"/>
- </resultMap>
- <sql id="Base_Column_List" >
- DIP_ID, DIO_ID, DIP_PropCode, DIP_PropName, DIP_Operation_Time, DIP_Operator, DIP_SupID,
- DIP_IsDel,DIP_Sort
- </sql>
- <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
- select
- <include refid="Base_Column_List" />
- from dic_io_property
- where DIP_ID = #{dipId,jdbcType=INTEGER} order by DIP_Sort desc
- </select>
- <select id="selectByDioId" resultMap="BaseResultMap" parameterType="java.lang.Integer">
- select
- <include refid="Base_Column_List" />
- from dic_io_property
- where DIO_ID = #{dioId,jdbcType=INTEGER} and DIP_IsDel = 0 order by DIP_Sort desc
- </select>
- <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
- delete from dic_io_property
- where DIP_ID = #{dipId,jdbcType=INTEGER}
- </delete>
- <insert id="insert" parameterType="com.xinxin.topro.sysservice.dao.mysqlmodel.SysDicIoProperty" >
- insert into dic_io_property (DIP_ID, DIO_ID, DIP_PropCode,
- DIP_PropName, DIP_Operation_Time, DIP_Operator,
- DIP_SupID, DIP_IsDel,DIP_Sort)
- values (#{dipId,jdbcType=INTEGER}, #{dioId,jdbcType=INTEGER}, #{dipPropcode,jdbcType=VARCHAR},
- #{dipPropname,jdbcType=VARCHAR}, #{dipOperationTime,jdbcType=TIMESTAMP}, #{dipOperator,jdbcType=VARCHAR},
- #{dipSupid,jdbcType=INTEGER}, #{dipIsdel,jdbcType=INTEGER},#{dipSort,jdbcType=INTEGER})
- </insert>
- <insert id="addProperty" parameterType="com.xinxin.topro.sysservice.dao.mysqlmodel.SysDicIoProperty" >
- insert into dic_io_property (DIO_ID, DIP_PropCode,
- DIP_PropName, DIP_Operation_Time, DIP_Operator,
- DIP_SupID, DIP_IsDel,DIP_Sort)
- values (#{dioId,jdbcType=INTEGER}, #{dipPropcode,jdbcType=VARCHAR},
- #{dipPropname,jdbcType=VARCHAR}, now(), #{dipOperator,jdbcType=VARCHAR},
- #{dipSupid,jdbcType=INTEGER}, #{dipIsdel,jdbcType=INTEGER},#{dipSort,jdbcType=INTEGER})
- </insert>
- <insert id="insertSelective" parameterType="com.xinxin.topro.sysservice.dao.mysqlmodel.SysDicIoProperty" >
- insert into dic_io_property
- <trim prefix="(" suffix=")" suffixOverrides="," >
- <if test="dipId != null" >
- DIP_ID,
- </if>
- <if test="dioId != null" >
- DIO_ID,
- </if>
- <if test="dipPropcode != null" >
- DIP_PropCode,
- </if>
- <if test="dipPropname != null" >
- DIP_PropName,
- </if>
- <if test="dipOperationTime != null" >
- DIP_Operation_Time,
- </if>
- <if test="dipOperator != null" >
- DIP_Operator,
- </if>
- <if test="dipSupid != null" >
- DIP_SupID,
- </if>
- <if test="dipIsdel != null" >
- DIP_IsDel,
- </if>
- <if test="dipSort != null" >
- DIP_Sort,
- </if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides="," >
- <if test="dipId != null" >
- #{dipId,jdbcType=INTEGER},
- </if>
- <if test="dioId != null" >
- #{dioId,jdbcType=INTEGER},
- </if>
- <if test="dipPropcode != null" >
- #{dipPropcode,jdbcType=VARCHAR},
- </if>
- <if test="dipPropname != null" >
- #{dipPropname,jdbcType=VARCHAR},
- </if>
- <if test="dipOperationTime != null" >
- #{dipOperationTime,jdbcType=TIMESTAMP},
- </if>
- <if test="dipOperator != null" >
- #{dipOperator,jdbcType=VARCHAR},
- </if>
- <if test="dipSupid != null" >
- #{dipSupid,jdbcType=INTEGER},
- </if>
- <if test="dipIsdel != null" >
- #{dipIsdel,jdbcType=INTEGER},
- </if>
- <if test="dipSort != null" >
- #{dipSort,jdbcType=INTEGER},
- </if>
- </trim>
- </insert>
- <update id="updateByPrimaryKeySelective" parameterType="com.xinxin.topro.sysservice.dao.mysqlmodel.SysDicIoProperty" >
- update dic_io_property
- <set >
- <if test="dioId != null" >
- DIO_ID = #{dioId,jdbcType=INTEGER},
- </if>
- <if test="dipPropcode != null" >
- DIP_PropCode = #{dipPropcode,jdbcType=VARCHAR},
- </if>
- <if test="dipPropname != null" >
- DIP_PropName = #{dipPropname,jdbcType=VARCHAR},
- </if>
- <if test="dipOperationTime != null" >
- DIP_Operation_Time = #{dipOperationTime,jdbcType=TIMESTAMP},
- </if>
- <if test="dipOperator != null" >
- DIP_Operator = #{dipOperator,jdbcType=VARCHAR},
- </if>
- <if test="dipSupid != null" >
- DIP_SupID = #{dipSupid,jdbcType=INTEGER},
- </if>
- <if test="dipIsdel != null" >
- DIP_IsDel = #{dipIsdel,jdbcType=INTEGER},
- </if>
- <if test="dipSort != null" >
- DIP_Sort = #{dipSort,jdbcType=INTEGER},
- </if>
- </set>
- where DIP_ID = #{dipId,jdbcType=INTEGER}
- </update>
- <update id="updateByPrimaryKey" parameterType="com.xinxin.topro.sysservice.dao.mysqlmodel.SysDicIoProperty" >
- update dic_io_property
- set DIO_ID = #{dioId,jdbcType=INTEGER},
- DIP_PropCode = #{dipPropcode,jdbcType=VARCHAR},
- DIP_PropName = #{dipPropname,jdbcType=VARCHAR},
- DIP_Operation_Time = #{dipOperationTime,jdbcType=TIMESTAMP},
- DIP_Operator = #{dipOperator,jdbcType=VARCHAR},
- DIP_SupID = #{dipSupid,jdbcType=INTEGER},
- DIP_IsDel = #{dipIsdel,jdbcType=INTEGER},
- DIP_Sorrt = #{dipSort,jdbcType=INTEGER}
- where DIP_ID = #{dipId,jdbcType=INTEGER}
- </update>
- <update id="delProperty" parameterType="java.lang.Integer" >
- update dic_io_property
- set DIP_IsDel = -1
- where DIP_ID = #{dipId,jdbcType=INTEGER}
- </update>
- <update id="delPropertyBySupId" parameterType="java.lang.Integer" >
- update dic_io_property
- set DIP_IsDel = -1
- where DIP_SupID = #{supId,jdbcType=INTEGER}
- </update>
- <update id="delPropertyByDioId" parameterType="java.lang.Integer" >
- update dic_io_property
- set DIP_IsDel = -1
- where DIO_ID = #{dioId,jdbcType=INTEGER}
- </update>
- <select id="selectByCode" resultMap="BaseResultMap" parameterType="java.lang.String">
- select <include refid="Base_Column_List"/>
- from dic_io_property
- where DIP_PropCode=#{dipPropcode,jdbcType=VARCHAR} and DIP_IsDel=0
- </select>
- </mapper>
|