|
|
@@ -0,0 +1,344 @@
|
|
|
+<?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.railway.business.catenary.mapper.BusDmcgyqMapper">
|
|
|
+
|
|
|
+ <resultMap id="BaseResultMap" type="com.railway.business.catenary.domain.BusDmcgyq">
|
|
|
+ <result column="id" property="id"/>
|
|
|
+ <result column="db" property="db"/>
|
|
|
+ <result column="dept_id" property="deptId"/>
|
|
|
+ <result column="bm" property="bm"/>
|
|
|
+ <result column="xb" property="xb"/>
|
|
|
+ <result column="qj" property="qj"/>
|
|
|
+ <result column="hb" property="hb"/>
|
|
|
+ <result column="zzh" property="zzh"/>
|
|
|
+ <result column="gd" property="gd"/>
|
|
|
+ <result column="gxms" property="gxms"/>
|
|
|
+ <result column="fxcs" property="fxcs"/>
|
|
|
+ <result column="fxmc" property="fxmc"/>
|
|
|
+ <result column="mdh" property="mdh"/>
|
|
|
+ <result column="sbbh" property="sbbh"/>
|
|
|
+ <result column="gzlx" property="gzlx"/>
|
|
|
+ <result column="czlc" property="czlc"/>
|
|
|
+ <result column="fxzxlc" property="fxzxlc"/>
|
|
|
+ <result column="sccj" property="sccj"/>
|
|
|
+ <result column="xh" property="xh"/>
|
|
|
+ <result column="del_flag" property="delFlag"/>
|
|
|
+ <result column="create_by" property="createBy"/>
|
|
|
+ <result column="create_time" property="createTime"/>
|
|
|
+ <result column="update_by" property="updateBy"/>
|
|
|
+ <result column="update_time" property="updateTime"/>
|
|
|
+ <result column="sjbh" property="sjbh"/>
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+ <sql id="Base_Column_List">
|
|
|
+ id,
|
|
|
+ db,
|
|
|
+ dept_id,
|
|
|
+ bm,
|
|
|
+ xb,
|
|
|
+ qj,
|
|
|
+ hb,
|
|
|
+ zzh,
|
|
|
+ gd,
|
|
|
+ gxms,
|
|
|
+ fxcs,
|
|
|
+ fxmc,
|
|
|
+ mdh,
|
|
|
+ sbbh,
|
|
|
+ gzlx,
|
|
|
+ czlc,
|
|
|
+ fxzxlc,
|
|
|
+ sccj,
|
|
|
+ xh,
|
|
|
+ del_flag,
|
|
|
+ create_by,
|
|
|
+ create_time,
|
|
|
+ update_by,
|
|
|
+ update_time,
|
|
|
+ sjbh
|
|
|
+ </sql>
|
|
|
+
|
|
|
+ <insert id="insert" parameterType="com.railway.business.catenary.domain.BusDmcgyq">
|
|
|
+ <selectKey keyProperty="id" order="BEFORE" resultType="String">
|
|
|
+ select replace(uuid(), '-', '') from dual
|
|
|
+ </selectKey>
|
|
|
+ INSERT INTO bus_dmcgyq
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test ='null != db'>
|
|
|
+ db,
|
|
|
+ </if>
|
|
|
+ <if test ='null != deptId'>
|
|
|
+ dept_id,
|
|
|
+ </if>
|
|
|
+ <if test ='null != bm'>
|
|
|
+ bm,
|
|
|
+ </if>
|
|
|
+ <if test ='null != xb'>
|
|
|
+ xb,
|
|
|
+ </if>
|
|
|
+ <if test ='null != qj'>
|
|
|
+ qj,
|
|
|
+ </if>
|
|
|
+ <if test ='null != hb'>
|
|
|
+ hb,
|
|
|
+ </if>
|
|
|
+ <if test ='null != zzh'>
|
|
|
+ zzh,
|
|
|
+ </if>
|
|
|
+ <if test ='null != gd'>
|
|
|
+ gd,
|
|
|
+ </if>
|
|
|
+ <if test ='null != gxms'>
|
|
|
+ gxms,
|
|
|
+ </if>
|
|
|
+ <if test ='null != fxcs'>
|
|
|
+ fxcs,
|
|
|
+ </if>
|
|
|
+ <if test ='null != fxmc'>
|
|
|
+ fxmc,
|
|
|
+ </if>
|
|
|
+ <if test ='null != mdh'>
|
|
|
+ mdh,
|
|
|
+ </if>
|
|
|
+ <if test ='null != sbbh'>
|
|
|
+ sbbh,
|
|
|
+ </if>
|
|
|
+ <if test ='null != gzlx'>
|
|
|
+ gzlx,
|
|
|
+ </if>
|
|
|
+ <if test ='null != czlc'>
|
|
|
+ czlc,
|
|
|
+ </if>
|
|
|
+ <if test ='null != fxzxlc'>
|
|
|
+ fxzxlc,
|
|
|
+ </if>
|
|
|
+ <if test ='null != sccj'>
|
|
|
+ sccj,
|
|
|
+ </if>
|
|
|
+ <if test ='null != xh'>
|
|
|
+ xh,
|
|
|
+ </if>
|
|
|
+ <if test ='null != delFlag'>
|
|
|
+ del_flag,
|
|
|
+ </if>
|
|
|
+ <if test ='null != createBy'>
|
|
|
+ create_by,
|
|
|
+ </if>
|
|
|
+ <if test ='null != createTime'>
|
|
|
+ create_time,
|
|
|
+ </if>
|
|
|
+ <if test ='null != updateBy'>
|
|
|
+ update_by,
|
|
|
+ </if>
|
|
|
+ <if test ='null != updateTime'>
|
|
|
+ update_time,
|
|
|
+ </if>
|
|
|
+ <if test ='null != sjbh'>
|
|
|
+ sjbh
|
|
|
+ </if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test ='null != db'>
|
|
|
+ #{db},
|
|
|
+ </if>
|
|
|
+ <if test ='null != deptId'>
|
|
|
+ #{deptId},
|
|
|
+ </if>
|
|
|
+ <if test ='null != bm'>
|
|
|
+ #{bm},
|
|
|
+ </if>
|
|
|
+ <if test ='null != xb'>
|
|
|
+ #{xb},
|
|
|
+ </if>
|
|
|
+ <if test ='null != qj'>
|
|
|
+ #{qj},
|
|
|
+ </if>
|
|
|
+ <if test ='null != hb'>
|
|
|
+ #{hb},
|
|
|
+ </if>
|
|
|
+ <if test ='null != zzh'>
|
|
|
+ #{zzh},
|
|
|
+ </if>
|
|
|
+ <if test ='null != gd'>
|
|
|
+ #{gd},
|
|
|
+ </if>
|
|
|
+ <if test ='null != gxms'>
|
|
|
+ #{gxms},
|
|
|
+ </if>
|
|
|
+ <if test ='null != fxcs'>
|
|
|
+ #{fxcs},
|
|
|
+ </if>
|
|
|
+ <if test ='null != fxmc'>
|
|
|
+ #{fxmc},
|
|
|
+ </if>
|
|
|
+ <if test ='null != mdh'>
|
|
|
+ #{mdh},
|
|
|
+ </if>
|
|
|
+ <if test ='null != sbbh'>
|
|
|
+ #{sbbh},
|
|
|
+ </if>
|
|
|
+ <if test ='null != gzlx'>
|
|
|
+ #{gzlx},
|
|
|
+ </if>
|
|
|
+ <if test ='null != czlc'>
|
|
|
+ #{czlc},
|
|
|
+ </if>
|
|
|
+ <if test ='null != fxzxlc'>
|
|
|
+ #{fxzxlc},
|
|
|
+ </if>
|
|
|
+ <if test ='null != sccj'>
|
|
|
+ #{sccj},
|
|
|
+ </if>
|
|
|
+ <if test ='null != xh'>
|
|
|
+ #{xh},
|
|
|
+ </if>
|
|
|
+ <if test ='null != delFlag'>
|
|
|
+ #{delFlag},
|
|
|
+ </if>
|
|
|
+ <if test ='null != createBy'>
|
|
|
+ #{createBy},
|
|
|
+ </if>
|
|
|
+ <if test ='null != createTime'>
|
|
|
+ #{createTime},
|
|
|
+ </if>
|
|
|
+ <if test ='null != updateBy'>
|
|
|
+ #{updateBy},
|
|
|
+ </if>
|
|
|
+ <if test ='null != updateTime'>
|
|
|
+ #{updateTime},
|
|
|
+ </if>
|
|
|
+ <if test ='null != sjbh'>
|
|
|
+ #{sjbh}
|
|
|
+ </if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <delete id="delete">
|
|
|
+ UPDATE bus_dmcgyq
|
|
|
+ set del_flag='1'
|
|
|
+ WHERE id = #{id}
|
|
|
+ </delete>
|
|
|
+
|
|
|
+ <update id="update" parameterType="com.railway.business.catenary.domain.BusDmcgyq">
|
|
|
+ UPDATE bus_dmcgyq
|
|
|
+ <set>
|
|
|
+ <if test ='null != db'>db = #{db},</if>
|
|
|
+ <if test ='null != deptId'>dept_id = #{deptId},</if>
|
|
|
+ <if test ='null != bm'>bm = #{bm},</if>
|
|
|
+ <if test ='null != xb'>xb = #{xb},</if>
|
|
|
+ <if test ='null != qj'>qj = #{qj},</if>
|
|
|
+ <if test ='null != hb'>hb = #{hb},</if>
|
|
|
+ <if test ='null != zzh'>zzh = #{zzh},</if>
|
|
|
+ <if test ='null != gd'>gd = #{gd},</if>
|
|
|
+ <if test ='null != gxms'>gxms = #{gxms},</if>
|
|
|
+ <if test ='null != fxcs'>fxcs = #{fxcs},</if>
|
|
|
+ <if test ='null != fxmc'>fxmc = #{fxmc},</if>
|
|
|
+ <if test ='null != mdh'>mdh = #{mdh},</if>
|
|
|
+ <if test ='null != sbbh'>sbbh = #{sbbh},</if>
|
|
|
+ <if test ='null != gzlx'>gzlx = #{gzlx},</if>
|
|
|
+ <if test ='null != czlc'>czlc = #{czlc},</if>
|
|
|
+ <if test ='null != fxzxlc'>fxzxlc = #{fxzxlc},</if>
|
|
|
+ <if test ='null != sccj'>sccj = #{sccj},</if>
|
|
|
+ <if test ='null != xh'>xh = #{xh},</if>
|
|
|
+ <if test ='null != delFlag'>del_flag = #{delFlag},</if>
|
|
|
+ <if test ='null != createBy'>create_by = #{createBy},</if>
|
|
|
+ <if test ='null != createTime'>create_time = #{createTime},</if>
|
|
|
+ <if test ='null != updateBy'>update_by = #{updateBy},</if>
|
|
|
+ <if test ='null != updateTime'>update_time = #{updateTime},</if>
|
|
|
+ <if test ='null != sjbh'>sjbh = #{sjbh}</if>
|
|
|
+ </set>
|
|
|
+ WHERE id = #{id}
|
|
|
+ </update>
|
|
|
+
|
|
|
+
|
|
|
+ <select id="getInfo" resultMap="BaseResultMap">
|
|
|
+ SELECT
|
|
|
+ <include refid="Base_Column_List"/>
|
|
|
+ FROM bus_dmcgyq
|
|
|
+ WHERE del_flag='0' and id = #{id}
|
|
|
+
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="getList" resultMap="BaseResultMap">
|
|
|
+ SELECT
|
|
|
+ <include refid="Base_Column_List"/>
|
|
|
+ FROM bus_dmcgyq
|
|
|
+ <where>
|
|
|
+ del_flag='0'
|
|
|
+ <if test="db!=null and db!=''">
|
|
|
+ and db=#{db}
|
|
|
+ </if>
|
|
|
+ <if test="deptId!=null and deptId!=''">
|
|
|
+ and dept_id=#{deptId}
|
|
|
+ </if>
|
|
|
+ <if test="bm!=null and bm!=''">
|
|
|
+ and bm=#{bm}
|
|
|
+ </if>
|
|
|
+ <if test="xb!=null and xb!=''">
|
|
|
+ and xb=#{xb}
|
|
|
+ </if>
|
|
|
+ <if test="qj!=null and qj!=''">
|
|
|
+ and qj=#{qj}
|
|
|
+ </if>
|
|
|
+ <if test="hb!=null and hb!=''">
|
|
|
+ and hb=#{hb}
|
|
|
+ </if>
|
|
|
+ <if test="zzh!=null and zzh!=''">
|
|
|
+ and zzh=#{zzh}
|
|
|
+ </if>
|
|
|
+ <if test="gd!=null and gd!=''">
|
|
|
+ and gd=#{gd}
|
|
|
+ </if>
|
|
|
+ <if test="gxms!=null and gxms!=''">
|
|
|
+ and gxms=#{gxms}
|
|
|
+ </if>
|
|
|
+ <if test="fxcs!=null and fxcs!=''">
|
|
|
+ and fxcs=#{fxcs}
|
|
|
+ </if>
|
|
|
+ <if test="fxmc!=null and fxmc!=''">
|
|
|
+ and fxmc=#{fxmc}
|
|
|
+ </if>
|
|
|
+ <if test="mdh!=null and mdh!=''">
|
|
|
+ and mdh=#{mdh}
|
|
|
+ </if>
|
|
|
+ <if test="sbbh!=null and sbbh!=''">
|
|
|
+ and sbbh=#{sbbh}
|
|
|
+ </if>
|
|
|
+ <if test="gzlx!=null and gzlx!=''">
|
|
|
+ and gzlx=#{gzlx}
|
|
|
+ </if>
|
|
|
+ <if test="czlc!=null and czlc!=''">
|
|
|
+ and czlc=#{czlc}
|
|
|
+ </if>
|
|
|
+ <if test="fxzxlc!=null and fxzxlc!=''">
|
|
|
+ and fxzxlc=#{fxzxlc}
|
|
|
+ </if>
|
|
|
+ <if test="sccj!=null and sccj!=''">
|
|
|
+ and sccj=#{sccj}
|
|
|
+ </if>
|
|
|
+ <if test="xh!=null and xh!=''">
|
|
|
+ and xh=#{xh}
|
|
|
+ </if>
|
|
|
+ <if test="delFlag!=null and delFlag!=''">
|
|
|
+ and del_flag=#{delFlag}
|
|
|
+ </if>
|
|
|
+ <if test="createBy!=null and createBy!=''">
|
|
|
+ and create_by=#{createBy}
|
|
|
+ </if>
|
|
|
+ <if test="createTime!=null and createTime!=''">
|
|
|
+ and create_time=#{createTime}
|
|
|
+ </if>
|
|
|
+ <if test="updateBy!=null and updateBy!=''">
|
|
|
+ and update_by=#{updateBy}
|
|
|
+ </if>
|
|
|
+ <if test="updateTime!=null and updateTime!=''">
|
|
|
+ and update_time=#{updateTime}
|
|
|
+ </if>
|
|
|
+ <if test="sjbh!=null and sjbh!=''">
|
|
|
+ and sjbh=#{sjbh}
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
+ </select>
|
|
|
+
|
|
|
+</mapper>
|