| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170 |
- <?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="cn.com.goldenwater.dcproj.dao.TacTacInspPersPrisLtsDao">
- <resultMap type="cn.com.goldenwater.dcproj.model.TacTacInspPersPrisLts" id="tacTacInspPersPrisLtsResultMap">
- <result property="id" column="ID"/>
- <result property="persPrisId" column="PERS_PRIS_ID"/>
- <result property="tenetType" column="TENET_TYPE"/>
- <result property="totalSize" column="TOTAL_SIZE"/>
- <result property="specialSize" column="SPECIAL_SIZE"/>
- <result property="assistantSize" column="ASSISTANT_SIZE"/>
- <result property="earlyTisSize" column="EARLY_TIS_SIZE"/>
- <result property="devemanageTisSize" column="DEVEMANAGE_TIS_SIZE"/>
- <result property="planTisSize" column="PLAN_TIS_SIZE"/>
- <result property="financeTisSize" column="FINANCE_TIS_SIZE"/>
- <result property="qualityTisSize" column="QUALITY_TIS_SIZE"/>
- <result property="safetyTisSize" column="SAFETY_TIS_SIZE"/>
- <result property="persId" column="PERS_ID"/>
- <result property="inTm" column="IN_TM"/>
- <result property="upTm" column="UP_TM"/>
- <result property="dataStat" column="DATA_STAT"/>
- </resultMap>
-
- <sql id="table_columns">
- ID,
- PERS_PRIS_ID,
- TENET_TYPE,
- TOTAL_SIZE,
- SPECIAL_SIZE,
- ASSISTANT_SIZE,
- EARLY_TIS_SIZE,
- DEVEMANAGE_TIS_SIZE,
- PLAN_TIS_SIZE,
- FINANCE_TIS_SIZE,
- QUALITY_TIS_SIZE,
- SAFETY_TIS_SIZE,
- PERS_ID,
- IN_TM,
- UP_TM,
- DATA_STAT
- </sql>
- <sql id="entity_properties">
- #{id},
- #{persPrisId},
- #{tenetType},
- #{totalSize},
- #{specialSize},
- #{assistantSize},
- #{earlyTisSize},
- #{devemanageTisSize},
- #{planTisSize},
- #{financeTisSize},
- #{qualityTisSize},
- #{safetyTisSize},
- #{persId},
- #{inTm},
- #{upTm},
- #{dataStat}
- </sql>
- <!-- 使用like用法:columnName like concat('%',#columnName#,'%') -->
- <sql id="page_where">
- <trim prefix="where" prefixOverrides="and | or ">
- <if test="persPrisId != null and persPrisId != ''">and PERS_PRIS_ID = #{persPrisId}</if>
- <if test="tenetType != null and tenetType != ''">and TENET_TYPE = #{tenetType}</if>
- <if test="totalSize != null and totalSize != ''">and TOTAL_SIZE = #{totalSize}</if>
- <if test="specialSize != null and specialSize != ''">and SPECIAL_SIZE = #{specialSize}</if>
- <if test="assistantSize != null and assistantSize != ''">and ASSISTANT_SIZE = #{assistantSize}</if>
- <if test="earlyTisSize != null and earlyTisSize != ''">and EARLY_TIS_SIZE = #{earlyTisSize}</if>
- <if test="devemanageTisSize != null and devemanageTisSize != ''">and DEVEMANAGE_TIS_SIZE = #{devemanageTisSize}</if>
- <if test="planTisSize != null and planTisSize != ''">and PLAN_TIS_SIZE = #{planTisSize}</if>
- <if test="financeTisSize != null and financeTisSize != ''">and FINANCE_TIS_SIZE = #{financeTisSize}</if>
- <if test="qualityTisSize != null and qualityTisSize != ''">and QUALITY_TIS_SIZE = #{qualityTisSize}</if>
- <if test="safetyTisSize != null and safetyTisSize != ''">and SAFETY_TIS_SIZE = #{safetyTisSize}</if>
- <if test="persId != null and persId != ''">and PERS_ID = #{persId}</if>
- <if test="inTm != null">and IN_TM = #{inTm}</if>
- <if test="upTm != null">and UP_TM = #{upTm}</if>
- <if test="dataStat != null and dataStat != ''">and DATA_STAT = #{dataStat}</if>
- </trim>
- </sql>
- <select id="get" resultMap="tacTacInspPersPrisLtsResultMap" parameterType="String" >
- select <include refid="table_columns" /> from TAC_TAC_INSP_PERS_PRIS_LTS where ID = #{id}
- </select>
- <select id="getBy" resultMap="tacTacInspPersPrisLtsResultMap">
- select <include refid="table_columns" /> from TAC_TAC_INSP_PERS_PRIS_LTS <include refid="page_where" />
- </select>
- <select id="findAll" resultMap="tacTacInspPersPrisLtsResultMap">
- select <include refid="table_columns" /> from TAC_TAC_INSP_PERS_PRIS_LTS
- </select>
- <select id="findList" resultMap="tacTacInspPersPrisLtsResultMap">
- select <include refid="table_columns" /> from TAC_TAC_INSP_PERS_PRIS_LTS <include refid="page_where" />
- </select>
- <select id="selectCount" resultType="int" >
- select count(ID) from TAC_TAC_INSP_PERS_PRIS_LTS <include refid="page_where" />
- </select>
- <insert id="insert" parameterType="cn.com.goldenwater.dcproj.model.TacTacInspPersPrisLts">
- insert into TAC_TAC_INSP_PERS_PRIS_LTS( <include refid="table_columns" /> )
- values ( <include refid="entity_properties" /> )
- </insert>
- <delete id="delete" parameterType="java.lang.String">
- delete from TAC_TAC_INSP_PERS_PRIS_LTS where ID = #{id}
- </delete>
- <delete id="deleteBy" parameterType="cn.com.goldenwater.dcproj.model.TacTacInspPersPrisLts">
- delete from TAC_TAC_INSP_PERS_PRIS_LTS <include refid="page_where" />
- </delete>
- <update id="deleteInFlag" parameterType="java.lang.String">
- update TAC_TAC_INSP_PERS_PRIS_LTS set flag_valid = 0 where ID = #{id}
- </update>
- <update id="update" parameterType="cn.com.goldenwater.dcproj.model.TacTacInspPersPrisLts">
- update TAC_TAC_INSP_PERS_PRIS_LTS
- <trim prefix="set" suffixOverrides=",">
- <if test="persPrisId != null and persPrisId != ''">PERS_PRIS_ID = #{persPrisId},</if>
- <if test="tenetType != null and tenetType != ''">TENET_TYPE = #{tenetType},</if>
- TOTAL_SIZE = #{totalSize},
- SPECIAL_SIZE = #{specialSize},
- ASSISTANT_SIZE = #{assistantSize},
- EARLY_TIS_SIZE = #{earlyTisSize},
- DEVEMANAGE_TIS_SIZE = #{devemanageTisSize},
- PLAN_TIS_SIZE = #{planTisSize},
- FINANCE_TIS_SIZE = #{financeTisSize},
- QUALITY_TIS_SIZE = #{qualityTisSize},
- SAFETY_TIS_SIZE = #{safetyTisSize},
- <if test="persId != null and persId != ''">PERS_ID = #{persId},</if>
- <if test="inTm != null">IN_TM = #{inTm},</if>
- <if test="upTm != null">UP_TM = #{upTm},</if>
- <if test="dataStat != null and dataStat != ''">DATA_STAT = #{dataStat},</if>
- </trim>
- <where>ID = #{id}</where>
- </update>
- <update id="updateBy" parameterType="cn.com.goldenwater.dcproj.model.TacTacInspPersPrisLts">
- update TAC_TAC_INSP_PERS_PRIS_LTS
- <trim prefix="set" suffixOverrides=",">
- <if test="persPrisId != null and persPrisId != ''">PERS_PRIS_ID = #{persPrisId},</if>
- <if test="tenetType != null and tenetType != ''">TENET_TYPE = #{tenetType},</if>
- <if test="totalSize != null and totalSize != ''">TOTAL_SIZE = #{totalSize},</if>
- <if test="specialSize != null and specialSize != ''">SPECIAL_SIZE = #{specialSize},</if>
- <if test="assistantSize != null and assistantSize != ''">ASSISTANT_SIZE = #{assistantSize},</if>
- <if test="earlyTisSize != null and earlyTisSize != ''">EARLY_TIS_SIZE = #{earlyTisSize},</if>
- <if test="devemanageTisSize != null and devemanageTisSize != ''">DEVEMANAGE_TIS_SIZE = #{devemanageTisSize},</if>
- <if test="planTisSize != null and planTisSize != ''">PLAN_TIS_SIZE = #{planTisSize},</if>
- <if test="financeTisSize != null and financeTisSize != ''">FINANCE_TIS_SIZE = #{financeTisSize},</if>
- <if test="qualityTisSize != null and qualityTisSize != ''">QUALITY_TIS_SIZE = #{qualityTisSize},</if>
- <if test="safetyTisSize != null and safetyTisSize != ''">SAFETY_TIS_SIZE = #{safetyTisSize},</if>
- <if test="persId != null and persId != ''">PERS_ID = #{persId},</if>
- <if test="inTm != null">IN_TM = #{inTm},</if>
- <if test="upTm != null">UP_TM = #{upTm},</if>
- <if test="dataStat != null and dataStat != ''">DATA_STAT = #{dataStat},</if>
- </trim>
- <include refid="page_where" />
- </update>
- <!-- 其他自定义SQL -->
- </mapper>
|