| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!-- 核三框架升级自动生成mapper文件 -->
- <!-- SDZL表牵涉到的sql文件 -->
- <!DOCTYPE mapper
- PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
- "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
- <mapper namespace="SDZL">
- <!-- SDZL 全字段 -->
- <sql id="SDZL_COL">
- SDZLID,SDZTID,SDJLID,ZLLBID,ZYS,GXSJ,BZ,
- ZLLRZT,SDFS,FS,SFGDBZ,SFBSBZ,DZZZBZ,ORDERNO
- </sql>
- <!-- SDZL 选择字段 -->
- <sql id="SDZL_COLSEL">
- <trim suffixOverrides=",">
- <if test="SDZLID != null">
- SDZLID,
- </if>
- <if test="SDZTID != null">
- SDZTID,
- </if>
- <if test="SDJLID != null">
- SDJLID,
- </if>
- <if test="ZLLBID != null">
- ZLLBID,
- </if>
- <if test="ZYS != null">
- ZYS,
- </if>
- <if test="GXSJ != null">
- GXSJ,
- </if>
- <if test="BZ != null">
- BZ,
- </if>
- <if test="ZLLRZT != null">
- ZLLRZT,
- </if>
- <if test="SDFS != null">
- SDFS,
- </if>
- <if test="FS != null">
- FS,
- </if>
- <if test="SFGDBZ != null">
- SFGDBZ,
- </if>
- <if test="SFBSBZ != null">
- SFBSBZ,
- </if>
- <if test="DZZZBZ != null">
- DZZZBZ,
- </if>
- <if test="ORDERNO != null">
- ORDERNO
- </if>
- </trim>
- </sql>
- <!-- SDZL 记录数 -->
- <select id="SDZL_CNT" parameterType="hashmap" resultType="long">
- select count(1)
- from SDZL
- <where>
- <if test="SDZLID != null">
- and SDZLID=#{SDZLID}
- </if>
- <if test="SDZTID != null">
- and SDZTID=#{SDZTID}
- </if>
- <if test="SDJLID != null">
- and SDJLID=#{SDJLID}
- </if>
- <if test="ZLLBID != null">
- and ZLLBID=#{ZLLBID}
- </if>
- <if test="ZYS != null">
- and ZYS=#{ZYS}
- </if>
- <if test="GXSJ != null">
- and GXSJ=#{GXSJ}
- </if>
- <if test="BZ != null">
- and BZ=#{BZ}
- </if>
- <if test="ZLLRZT != null">
- and ZLLRZT=#{ZLLRZT}
- </if>
- <if test="SDFS != null">
- and SDFS=#{SDFS}
- </if>
- <if test="FS != null">
- and FS=#{FS}
- </if>
- <if test="SFGDBZ != null">
- and SFGDBZ=#{SFGDBZ}
- </if>
- <if test="SFBSBZ != null">
- and SFBSBZ=#{SFBSBZ}
- </if>
- <if test="DZZZBZ != null">
- and DZZZBZ=#{DZZZBZ}
- </if>
- <if test="ORDERNO != null">
- and ORDERNO=#{ORDERNO}
- </if>
- </where>
- </select>
- <!-- SDZL 全字段查询 -->
- <select id="SDZL_Q" parameterType="hashmap" resultType="hashmap">
- select
- <include refid="SDZL_COL" /> <!--引用前边定义的所有字段 -->
- from SDZL
- <where>
- <if test="SDZLID != null">
- and SDZLID=#{SDZLID}
- </if>
- <if test="SDZTID != null">
- and SDZTID=#{SDZTID}
- </if>
- <if test="SDJLID != null">
- and SDJLID=#{SDJLID}
- </if>
- <if test="ZLLBID != null">
- and ZLLBID=#{ZLLBID}
- </if>
- <if test="ZYS != null">
- and ZYS=#{ZYS}
- </if>
- <if test="GXSJ != null">
- and GXSJ=#{GXSJ}
- </if>
- <if test="BZ != null">
- and BZ=#{BZ}
- </if>
- <if test="ZLLRZT != null">
- and ZLLRZT=#{ZLLRZT}
- </if>
- <if test="SDFS != null">
- and SDFS=#{SDFS}
- </if>
- <if test="FS != null">
- and FS=#{FS}
- </if>
- <if test="SFGDBZ != null">
- and SFGDBZ=#{SFGDBZ}
- </if>
- <if test="SFBSBZ != null">
- and SFBSBZ=#{SFBSBZ}
- </if>
- <if test="DZZZBZ != null">
- and DZZZBZ=#{DZZZBZ}
- </if>
- <if test="ORDERNO != null">
- and ORDERNO=#{ORDERNO}
- </if>
- </where>
- </select>
- <!-- SDZL 选择查询 -->
- <select id="SDZL_QS" parameterType="hashmap" resultType="hashmap">
- select
- <include refid="SDZL_COLSEL" /> <!--引用前边定义的所有字段 -->
- from SDZL
- <where>
- <if test="SDZLID != null">
- and SDZLID=#{SDZLID}
- </if>
- <if test="SDZTID != null">
- and SDZTID=#{SDZTID}
- </if>
- <if test="SDJLID != null">
- and SDJLID=#{SDJLID}
- </if>
- <if test="ZLLBID != null">
- and ZLLBID=#{ZLLBID}
- </if>
- <if test="ZYS != null">
- and ZYS=#{ZYS}
- </if>
- <if test="GXSJ != null">
- and GXSJ=#{GXSJ}
- </if>
- <if test="BZ != null">
- and BZ=#{BZ}
- </if>
- <if test="ZLLRZT != null">
- and ZLLRZT=#{ZLLRZT}
- </if>
- <if test="SDFS != null">
- and SDFS=#{SDFS}
- </if>
- <if test="FS != null">
- and FS=#{FS}
- </if>
- <if test="SFGDBZ != null">
- and SFGDBZ=#{SFGDBZ}
- </if>
- <if test="SFBSBZ != null">
- and SFBSBZ=#{SFBSBZ}
- </if>
- <if test="DZZZBZ != null">
- and DZZZBZ=#{DZZZBZ}
- </if>
- <if test="ORDERNO != null">
- and ORDERNO=#{ORDERNO}
- </if>
- </where>
- </select>
-
- <!-- SDZL 选择查询 -->
- <select id="SDZL_ZLLB_Q" parameterType="hashmap" resultType="hashmap">
- select a.SDZLID,(select ZLMC from SDZLSX where ZLLBID=a.ZLLBID) ZLLBMC,SFBSBZ,
- (select count(1) from SDZLMX where SDZLID=a.SDZLID and YXBZ='1') CNT
- from SDZL a where SDJLID=#{SDJLID}
- </select>
-
- <!-- SDZL 插入 -->
- <insert id="SDZL_I" parameterType="hashmap">
- insert into SDZL (
- SDZLID,SDZTID,SDJLID,ZLLBID,ZYS,GXSJ,BZ,
- ZLLRZT,SDFS,FS,SFGDBZ,SFBSBZ,DZZZBZ,ORDERNO
- ) values (
- #{SDZLID},#{SDZTID},#{SDJLID},#{ZLLBID},#{ZYS},#{GXSJ},#{BZ},
- #{ZLLRZT},#{SDFS},#{FS},#{SFGDBZ},#{SFBSBZ},#{DZZZBZ},#{ORDERNO}
- )
- </insert>
- <!-- SDZL 插入-类型映射 -->
- <insert id="SDZL_IT" parameterType="hashmap">
- insert into SDZL (
- SDZLID,SDZTID,SDJLID,ZLLBID,ZYS,GXSJ,BZ,
- ZLLRZT,SDFS,FS,SFGDBZ,SFBSBZ,DZZZBZ,ORDERNO
- ) values (
- #{SDZLID ,javaType=long,jdbcType=NUMERIC},#{SDZTID ,javaType=long,jdbcType=NUMERIC},
- #{SDJLID ,javaType=long,jdbcType=NUMERIC},#{ZLLBID ,javaType=long,jdbcType=NUMERIC},#{ZYS ,javaType=long,jdbcType=NUMERIC},
- #{GXSJ ,javaType=long,jdbcType=NUMERIC},#{BZ ,javaType=string,jdbcType=VARCHAR},#{ZLLRZT ,javaType=string,jdbcType=VARCHAR},
- #{SDFS ,javaType=string,jdbcType=VARCHAR},#{FS ,javaType=long,jdbcType=NUMERIC},#{SFGDBZ ,javaType=string,jdbcType=VARCHAR},
- #{SFBSBZ ,javaType=string,jdbcType=VARCHAR},#{DZZZBZ ,javaType=string,jdbcType=VARCHAR},#{ORDERNO ,javaType=long,jdbcType=NUMERIC}
- )
- </insert>
- <!-- SDZL 选择字段插入 -->
- <insert id="SDZL_IS" parameterType="hashmap">
- insert into SDZL (
- <trim suffixOverrides=",">
- <if test="SDZLID != null">SDZLID,</if>
- <if test="SDZTID != null">SDZTID,</if>
- <if test="SDJLID != null">SDJLID,</if>
- <if test="ZLLBID != null">ZLLBID,</if>
- <if test="ZYS != null">ZYS,</if>
- <if test="GXSJ != null">GXSJ,</if>
- <if test="BZ != null">BZ,</if>
- <if test="ZLLRZT != null">ZLLRZT,</if>
- <if test="SDFS != null">SDFS,</if>
- <if test="FS != null">FS,</if>
- <if test="SFGDBZ != null">SFGDBZ,</if>
- <if test="SFBSBZ != null">SFBSBZ,</if>
- <if test="DZZZBZ != null">DZZZBZ,</if>
- <if test="ORDERNO != null">ORDERNO,</if>
- <if test="YJFS != null">YJFS,</if>
- <if test="FYJFS != null">FYJFS,</if>
- <if test="CLSM != null">CLSM,</if>
- <if test="CLXS != null">CLXS,</if>
- </trim>
- ) values (
- <trim suffixOverrides=",">
- <if test="SDZLID != null">#{SDZLID},</if>
- <if test="SDZTID != null">#{SDZTID},</if>
- <if test="SDJLID != null">#{SDJLID},</if>
- <if test="ZLLBID != null">#{ZLLBID},</if>
- <if test="ZYS != null">#{ZYS},</if>
- <if test="GXSJ != null">#{GXSJ},</if>
- <if test="BZ != null">#{BZ},</if>
- <if test="ZLLRZT != null">#{ZLLRZT},</if>
- <if test="SDFS != null">#{SDFS},</if>
- <if test="FS != null">#{FS},</if>
- <if test="SFGDBZ != null">#{SFGDBZ},</if>
- <if test="SFBSBZ != null">#{SFBSBZ},</if>
- <if test="DZZZBZ != null">#{DZZZBZ},</if>
- <if test="ORDERNO != null">#{ORDERNO},</if>
- <if test="YJFS != null">#{YJFS},</if>
- <if test="FYJFS != null">#{FYJFS},</if>
- <if test="CLSM != null">#{CLSM},</if>
- <if test="CLXS != null">#{CLXS},</if>
- </trim>
- )
- </insert>
- <!-- SDZL 修改 -->
- <update id="SDZL_U" parameterType="hashmap">
- update SDZL
- set
- SDZLID= #{SDZLID},SDZTID= #{SDZTID},SDJLID= #{SDJLID},
- ZLLBID= #{ZLLBID},ZYS= #{ZYS},GXSJ= #{GXSJ},BZ= #{BZ},
- ZLLRZT= #{ZLLRZT},SDFS= #{SDFS},FS= #{FS},SFGDBZ= #{SFGDBZ},
- SFBSBZ= #{SFBSBZ},DZZZBZ= #{DZZZBZ},ORDERNO= #{ORDERNO}
- where
- SDZLID = #{SDZLID}
- </update>
- <!-- SDZL 选择修改 -->
- <update id="SDZL_US" parameterType="hashmap">
- update SDZL
- set
- <trim suffixOverrides=",">
- <if test="SDZLID != null">SDZLID=#{SDZLID},</if>
- <if test="SDZTID != null">SDZTID=#{SDZTID},</if>
- <if test="SDJLID != null">SDJLID=#{SDJLID},</if>
- <if test="ZLLBID != null">ZLLBID=#{ZLLBID},</if>
- <if test="ZYS != null">ZYS=#{ZYS},</if>
- <if test="GXSJ != null">GXSJ=#{GXSJ},</if>
- <if test="BZ != null">BZ=#{BZ},</if>
- <if test="ZLLRZT != null">ZLLRZT=#{ZLLRZT},</if>
- <if test="SDFS != null">SDFS=#{SDFS},</if>
- <if test="FS != null">FS=#{FS},</if>
- <if test="SFGDBZ != null">SFGDBZ=#{SFGDBZ},</if>
- <if test="SFBSBZ != null">SFBSBZ=#{SFBSBZ},</if>
- <if test="DZZZBZ != null">DZZZBZ=#{DZZZBZ},</if>
- <if test="ORDERNO != null">ORDERNO=#{ORDERNO},</if>
- </trim>
- where
- SDZLID = #{SDZLID}
- </update>
- <!-- SDZL 删除 -->
- <delete id="SDZL_D" parameterType="hashmap">
- delete from SDZL
- <where>
- SDZLID = #{SDZLID}
- </where>
- </delete>
- <!-- SDZL 序列 -->
- <select id="SDZLID_SEQ" parameterType="hashmap" resultType="string">
- select seq_sdzlid.nextval from dual
- </select>
- </mapper>
|