| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267 |
- <?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.AttWiuWatLicDao">
- <resultMap type="cn.com.goldenwater.dcproj.model.AttWiuWatLic" id="attWiuWatLicResultMap">
- <result property="certCond" column="CERT_COND"/>
- <result property="chkIntMet" column="CHK_INT_MET"/>
- <result property="intUse" column="INT_USE"/>
- <result property="chkSourTp" column="CHK_SOUR_TP"/>
- <result property="bkWw" column="BK_WW"/>
- <result property="rwAddr" column="RW_ADDR"/>
- <result property="rwTp" column="RW_TP"/>
- <result property="rwW" column="RW_W"/>
- <result property="rwWqReq" column="RW_WQ_REQ"/>
- <result property="apprOrgCd" column="APPR_ORG_CD"/>
- <result property="apprDt" column="APPR_DT"/>
- <result property="apprOrgName" column="APPR_ORG_NAME"/>
- <result property="id" column="ID"/>
- <result property="wiuId" column="WIU_ID"/>
- <result property="qsxkspqklx" column="QSXKSPQKLX"/>
- <result property="watLicCode" column="WAT_LIC_CODE"/>
- <result property="apprOrg" column="APPR_ORG"/>
- <result property="wiuBd" column="WIU_BD"/>
- <result property="wiuDl" column="WIU_DL"/>
- <result property="wrpNm" column="WRP_NM"/>
- <result property="wiuWw" column="WIU_WW"/>
- <result property="replSn" column="REPL_SN"/>
- <result property="applNm" column="APPL_NM"/>
- <result property="intBd" column="INT_BD"/>
- <result property="intDl" column="INT_DL"/>
- <result property="apprWw" column="APPR_WW"/>
- <result property="ftafawdp" column="FTAFAWDP"/>
- <result property="inTm" column="IN_TM"/>
- <result property="upTm" column="UP_TM"/>
- <result property="wintCode" column="WINT_CODE"/>
- <result property="wiuCode" column="WIU_CODE"/>
- <result property="wintPos" column="WINT_POS"/>
- <result property="name" column="NAME"/>
- <result property="manOrgCd" column="MAN_ORG_CD"/>
- <result property="manOrgName" column="MAN_ORG_NAME"/>
- </resultMap>
-
- <sql id="table_columns">
- CERT_COND,MAN_ORG_CD,MAN_ORG_NAME,
- CHK_INT_MET,
- INT_USE,
- CHK_SOUR_TP,
- BK_WW,
- RW_ADDR,
- RW_TP,
- RW_W,
- RW_WQ_REQ,
- APPR_ORG_CD,
- APPR_DT,
- APPR_ORG_NAME,
- ID,
- WIU_ID,
- QSXKSPQKLX,
- WAT_LIC_CODE,
- APPR_ORG,
- WIU_BD,
- WIU_DL,
- WRP_NM,
- WIU_WW,
- REPL_SN,
- APPL_NM,
- INT_BD,
- INT_DL,
- APPR_WW,
- FTAFAWDP,
- IN_TM,
- UP_TM
- </sql>
- <sql id="entity_properties">
- #{certCond},#{manOrgCd},#{manOrgName},
- #{chkIntMet},
- #{intUse},
- #{chkSourTp},
- #{bkWw},
- #{rwAddr},
- #{rwTp},
- #{rwW},
- #{rwWqReq},
- #{apprOrgCd},
- #{apprDt},
- #{apprOrgName},
- #{id},
- #{wiuId},
- #{qsxkspqklx},
- #{watLicCode},
- #{apprOrg},
- #{wiuBd},
- #{wiuDl},
- #{wrpNm},
- #{wiuWw},
- #{replSn},
- #{applNm},
- #{intBd},
- #{intDl},
- #{apprWw},
- #{ftafawdp},
- #{inTm},
- #{upTm}
- </sql>
- <!-- 使用like用法:columnName like concat('%',#columnName#,'%') -->
- <sql id="page_where">
- <trim prefix="where" prefixOverrides="and | or ">
- <if test="chkIntMet != null and chkIntMet != ''">and CHK_INT_MET like '%${chkIntMet}%'</if>
- <if test="intUse != null and intUse != ''">and INT_USE like '%${intUse}%'</if>
- <if test="chkSourTp != null and chkSourTp != ''">and CHK_SOUR_TP = #{chkSourTp}</if>
- <if test="bkWw != null and bkWw != ''">and BK_WW = #{bkWw}</if>
- <if test="rwAddr != null and rwAddr != ''">and RW_ADDR = #{rwAddr}</if>
- <if test="rwTp != null and rwTp != ''">and RW_TP = #{rwTp}</if>
- <if test="rwW != null and rwW != ''">and RW_W = #{rwW}</if>
- <if test="rwWqReq != null and rwWqReq != ''">and RW_WQ_REQ = #{rwWqReq}</if>
- <if test="apprOrgCd != null and apprOrgCd != ''">and APPR_ORG_CD = #{apprOrgCd}</if>
- <if test="apprDt != null">and APPR_DT = #{apprDt}</if>
- <if test="apprOrgName != null and apprOrgName != ''">and APPR_ORG_NAME = #{apprOrgName}</if>
- <if test="wiuId != null and wiuId != ''">and WIU_ID = #{wiuId}</if>
- <if test="qsxkspqklx != null and qsxkspqklx != ''">and QSXKSPQKLX = #{qsxkspqklx}</if>
- <if test="watLicCode != null and watLicCode != ''">and WAT_LIC_CODE like '%${watLicCode}%'</if>
- <if test="apprOrg != null and apprOrg != ''">and APPR_ORG = #{apprOrg}</if>
- <if test="wiuBd != null">and WIU_BD = #{wiuBd}</if>
- <if test="wiuDl != null">and WIU_DL = #{wiuDl}</if>
- <if test="wrpNm != null and wrpNm != ''">and WRP_NM like '%${wrpNm}%'</if>
- <if test="wiuWw != null and wiuWw != ''">and WIU_WW = #{wiuWw}</if>
- <if test="replSn != null and replSn != ''">and REPL_SN = #{replSn}</if>
- <if test="applNm != null and applNm != ''">and APPL_NM = #{applNm}</if>
- <if test="intBd != null">and INT_BD = #{intBd}</if>
- <if test="intDl != null">and INT_DL = #{intDl}</if>
- <if test="apprWw != null and apprWw != ''">and APPR_WW = #{apprWw}</if>
- <if test="ftafawdp != null and ftafawdp != ''">and FTAFAWDP = #{ftafawdp}</if>
- <if test="inTm != null">and IN_TM = #{inTm}</if>
- <if test="upTm != null">and UP_TM = #{upTm}</if>
- <if test="certCond != null and certCond !=''">and CERT_COND = #{certCond}</if>
- <if test="manOrgCd != null and manOrgCd !=''">and MAN_ORG_CD = #{manOrgCd}</if>
- <if test="manOrgName != null and manOrgName !=''">and MAN_ORG_NAME = #{manOrgName}</if>
- </trim>
- </sql>
- <select id="get" resultMap="attWiuWatLicResultMap" parameterType="String" >
- select l.*,w.name,w.wiu_code,a.wint_code,a.wint_pos from att_wiu_wat_lic l, att_wiu_base w,att_wint_base_b a where l.wiu_id=w.id and w.wint_code=a.id
- and l.id=#{id}
- </select>
- <select id="getBy" resultMap="attWiuWatLicResultMap">
- select <include refid="table_columns" /> from ATT_WIU_WAT_LIC <include refid="page_where" />
- </select>
- <select id="findNotNull" resultMap="attWiuWatLicResultMap">
- select * from att_wiu_wat_lic l where l.cert_Cond is not null
- </select>
- <select id="findISNull" resultMap="attWiuWatLicResultMap">
- select * from att_wiu_wat_lic l where l.cert_Cond is null
- </select>
- <select id="findAll" resultMap="attWiuWatLicResultMap">
- select <include refid="table_columns" /> from ATT_WIU_WAT_LIC
- </select>
- <select id="findList" resultMap="attWiuWatLicResultMap">
- select <include refid="table_columns" /> from ATT_WIU_WAT_LIC <include refid="page_where" />
- </select>
- <select id="selectCount" resultType="int" >
- select count(ID) from ATT_WIU_WAT_LIC <include refid="page_where" />
- </select>
- <insert id="insert" parameterType="cn.com.goldenwater.dcproj.model.AttWiuWatLic">
- insert into ATT_WIU_WAT_LIC( <include refid="table_columns" /> )
- values ( <include refid="entity_properties" /> )
- </insert>
- <delete id="delete" parameterType="java.lang.String">
- delete from ATT_WIU_WAT_LIC where ID = #{id}
- </delete>
- <delete id="deleteBy" parameterType="cn.com.goldenwater.dcproj.model.AttWiuWatLic">
- delete from ATT_WIU_WAT_LIC <include refid="page_where" />
- </delete>
- <update id="deleteInFlag" parameterType="java.lang.String">
- update ATT_WIU_WAT_LIC set flag_valid = 0 where ID = #{id}
- </update>
- <update id="update" parameterType="cn.com.goldenwater.dcproj.model.AttWiuWatLic">
- update ATT_WIU_WAT_LIC
- <trim prefix="set" suffixOverrides=",">
- <if test="chkIntMet != null and chkIntMet != ''">CHK_INT_MET = #{chkIntMet},</if>
- <if test="intUse != null and intUse != ''">INT_USE = #{intUse},</if>
- <if test="chkSourTp != null and chkSourTp != ''">CHK_SOUR_TP = #{chkSourTp},</if>
- <if test="bkWw != null and bkWw != ''">BK_WW = #{bkWw},</if>
- <if test="rwAddr != null and rwAddr != ''">RW_ADDR = #{rwAddr},</if>
- <if test="rwTp != null and rwTp != ''">RW_TP = #{rwTp},</if>
- <if test="rwW != null and rwW != ''">RW_W = #{rwW},</if>
- <if test="rwWqReq != null and rwWqReq != ''">RW_WQ_REQ = #{rwWqReq},</if>
- <if test="apprOrgCd != null and apprOrgCd != ''">APPR_ORG_CD = #{apprOrgCd},</if>
- <if test="apprDt != null">APPR_DT = #{apprDt},</if>
- <if test="apprOrgName != null and apprOrgName != ''">APPR_ORG_NAME = #{apprOrgName},</if>
- <if test="wiuId != null and wiuId != ''">WIU_ID = #{wiuId},</if>
- <if test="qsxkspqklx != null and qsxkspqklx != ''">QSXKSPQKLX = #{qsxkspqklx},</if>
- <if test="watLicCode != null and watLicCode != ''">WAT_LIC_CODE = #{watLicCode},</if>
- <if test="apprOrg != null and apprOrg != ''">APPR_ORG = #{apprOrg},</if>
- <if test="wiuBd != null">WIU_BD = #{wiuBd},</if>
- <if test="wiuDl != null">WIU_DL = #{wiuDl},</if>
- <if test="wrpNm != null and wrpNm != ''">WRP_NM = #{wrpNm},</if>
- <if test="wiuWw != null and wiuWw != ''">WIU_WW = #{wiuWw},</if>
- <if test="replSn != null and replSn != ''">REPL_SN = #{replSn},</if>
- <if test="applNm != null and applNm != ''">APPL_NM = #{applNm},</if>
- <if test="certCond != null"> CERT_COND = #{certCond},</if>
- <if test="intBd != null">INT_BD = #{intBd},</if>
- <if test="intDl != null">INT_DL = #{intDl},</if>
- <if test="apprWw != null and apprWw != ''">APPR_WW = #{apprWw},</if>
- <if test="ftafawdp != null and ftafawdp != ''">FTAFAWDP = #{ftafawdp},</if>
- <if test="inTm != null">IN_TM = #{inTm},</if>
- <if test="manOrgCd != null and manOrgCd !=''"> MAN_ORG_CD = #{manOrgCd},</if>
- <if test="manOrgName != null and manOrgName !=''"> MAN_ORG_NAME = #{manOrgName},</if>
- <if test="upTm != null">UP_TM = #{upTm},</if>
- </trim>
- <where>ID = #{id}</where>
- </update>
- <update id="updateBy" parameterType="cn.com.goldenwater.dcproj.model.AttWiuWatLic">
- update ATT_WIU_WAT_LIC
- <trim prefix="set" suffixOverrides=",">
- <if test="chkIntMet != null and chkIntMet != ''">CHK_INT_MET = #{chkIntMet},</if>
- <if test="intUse != null and intUse != ''">INT_USE = #{intUse},</if>
- <if test="chkSourTp != null and chkSourTp != ''">CHK_SOUR_TP = #{chkSourTp},</if>
- <if test="bkWw != null and bkWw != ''">BK_WW = #{bkWw},</if>
- <if test="rwAddr != null and rwAddr != ''">RW_ADDR = #{rwAddr},</if>
- <if test="rwTp != null and rwTp != ''">RW_TP = #{rwTp},</if>
- <if test="rwW != null and rwW != ''">RW_W = #{rwW},</if>
- <if test="rwWqReq != null and rwWqReq != ''">RW_WQ_REQ = #{rwWqReq},</if>
- <if test="apprOrgCd != null and apprOrgCd != ''">APPR_ORG_CD = #{apprOrgCd},</if>
- <if test="apprDt != null">APPR_DT = #{apprDt},</if>
- <if test="apprOrgName != null and apprOrgName != ''">APPR_ORG_NAME = #{apprOrgName},</if>
- <if test="wiuId != null and wiuId != ''">WIU_ID = #{wiuId},</if>
- <if test="qsxkspqklx != null and qsxkspqklx != ''">QSXKSPQKLX = #{qsxkspqklx},</if>
- <if test="watLicCode != null and watLicCode != ''">WAT_LIC_CODE = #{watLicCode},</if>
- <if test="apprOrg != null and apprOrg != ''">APPR_ORG = #{apprOrg},</if>
- <if test="wiuBd != null">WIU_BD = #{wiuBd},</if>
- <if test="wiuDl != null">WIU_DL = #{wiuDl},</if>
- <if test="manOrgCd != null and manOrgCd !=''"> MAN_ORG_CD = #{manOrgCd},</if>
- <if test="manOrgName != null and manOrgName !=''"> MAN_ORG_NAME = #{manOrgName},</if>
- <if test="wrpNm != null and wrpNm != ''">WRP_NM = #{wrpNm},</if>
- <if test="wiuWw != null and wiuWw != ''">WIU_WW = #{wiuWw},</if>
- <if test="replSn != null and replSn != ''">REPL_SN = #{replSn},</if>
- <if test="applNm != null and applNm != ''">APPL_NM = #{applNm},</if>
- <if test="intBd != null">INT_BD = #{intBd},</if>
- <if test="intDl != null">INT_DL = #{intDl},</if>
- <if test="apprWw != null and apprWw != ''">APPR_WW = #{apprWw},</if>
- <if test="ftafawdp != null and ftafawdp != ''">FTAFAWDP = #{ftafawdp},</if>
- <if test="inTm != null">IN_TM = #{inTm},</if>
- <if test="upTm != null">UP_TM = #{upTm},</if>
- </trim>
- <include refid="page_where" />
- </update>
- <!-- 其他自定义SQL -->
- </mapper>
|