| 
					
				 | 
			
			
				@@ -0,0 +1,180 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+<?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.steerinfo.ems.temergencymaterials.mapper.TEmergencymaterialsMapper"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <resultMap id="BaseResultMap" type="com.steerinfo.ems.temergencymaterials.model.TEmergencymaterials"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <id column="TNO" jdbcType="DECIMAL" property="tno" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="GX_CODE" jdbcType="DECIMAL" property="gx_code" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="GX_NAME" jdbcType="VARCHAR" property="gx_name" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="YJWZ_DD" jdbcType="VARCHAR" property="yjwz_dd" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="YJWZ_RY" jdbcType="VARCHAR" property="yjwz_ry" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="LXDH" jdbcType="VARCHAR" property="lxdh" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="WZDL_NAME" jdbcType="VARCHAR" property="wzdl_name" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="WZLB_NAME" jdbcType="VARCHAR" property="wzlb_name" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="SBMC_NAME" jdbcType="VARCHAR" property="sbmc_name" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="XH" jdbcType="VARCHAR" property="xh" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="DW" jdbcType="VARCHAR" property="dw" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="HSYJZ1" jdbcType="DECIMAL" property="hsyjz1" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="HSYJZ2" jdbcType="DECIMAL" property="hsyjz2" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="CJR" jdbcType="VARCHAR" property="cjr" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="CJSJ" jdbcType="VARCHAR" property="cjsj" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="MEMO" jdbcType="VARCHAR" property="memo" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <result column="KCL" jdbcType="DECIMAL" property="kcl" /> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </resultMap> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <sql id="columns"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    TNO, GX_CODE, GX_NAME, YJWZ_DD, YJWZ_RY, LXDH, WZDL_NAME, WZLB_NAME, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    SBMC_NAME, XH, DW, HSYJZ1, HSYJZ2, CJR, CJSJ, MEMO, KCL 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </sql> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <sql id="columns_alias"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    t.TNO, t.GX_CODE, t.GX_NAME, t.YJWZ_DD, t.YJWZ_RY, t.LXDH, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    t.WZDL_NAME, t.WZLB_NAME, t.SBMC_NAME, t.XH, t.DW, t.HSYJZ1, t.HSYJZ2, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    t.CJR, t.CJSJ, t.MEMO, t.KCL 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </sql> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <sql id="select"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        SELECT <include refid="columns"/>  FROM EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </sql> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <sql id="select_alias"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        SELECT <include refid="columns_alias"/> FROM EMS_YJWZ_BASEINFO t 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </sql> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <sql id="where"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="gx_name != null and gx_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and GX_NAME = #{gx_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzdl_name != null and wzdl_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZDL_NAME = #{wzdl_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzlb_name != null and wzlb_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZLB_NAME = #{wzlb_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="sbmc_name != null and sbmc_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and SBMC_NAME = #{sbmc_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="xh != null and xh != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and XH = #{xh} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        </where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </sql> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <sql id="whereLike"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="gx_name != null and gx_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and GX_NAME LIKE '%${gx_name}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzdl_name != null and wzdl_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZDL_NAME LIKE '%${wzdl_name}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzlb_name != null and wzlb_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZLB_NAME LIKE '%${wzlb_name}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="sbmc_name != null and sbmc_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and SBMC_NAME LIKE '%${sbmc_name}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="xh != null and xh != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and XH LIKE '%${xh}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        </where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </sql> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="select" resultMap="BaseResultMap" parameterType="string"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     SELECT * FROM EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+   </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="selectAll" resultMap="BaseResultMap" parameterType="string"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    select * from EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="PageselectAll" resultMap="BaseResultMap" parameterType="java.util.HashMap"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      select TNO, GX_CODE, GX_NAME, YJWZ_DD, YJWZ_RY, LXDH, WZDL_NAME, WZLB_NAME, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+       SBMC_NAME, XH, DW, HSYJZ1, HSYJZ2, CJR, CJSJ, MEMO, KCL 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      from EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            1 = 1 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="gx_name != null and gx_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and GX_NAME = #{gx_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzdl_name != null and wzdl_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZDL_NAME = #{wzdl_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzlb_name != null and wzlb_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZLB_NAME = #{wzlb_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="sbmc_name != null and sbmc_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and SBMC_NAME = #{sbmc_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="xh != null and xh != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and XH = #{xh} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        </where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="PageselectLikeAll" resultMap="BaseResultMap" parameterType="java.util.HashMap"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        select TNO, GX_CODE, GX_NAME, YJWZ_DD, YJWZ_RY, LXDH, WZDL_NAME, WZLB_NAME, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        SBMC_NAME, XH, DW, HSYJZ1, HSYJZ2, CJR, CJSJ, MEMO, KCL 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        from EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            1 = 1 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="gx_name != null and gx_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ${gx_name} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzdl_name != null and wzdl_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZDL_NAME LIKE '%${wzdl_name}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="wzlb_name != null and wzlb_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and WZLB_NAME LIKE '%${wzlb_name}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="sbmc_name != null and sbmc_name != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and SBMC_NAME LIKE '%${sbmc_name}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <if test="xh != null and xh != ''"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                and XH LIKE '%${xh}%' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </if> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        </where> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        order by TNO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="selectGxAll" resultType="java.lang.String"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        select name from T_RM_WORKPROC  where id in('AT1004','AT1006','AT1007','AT1008','AT1111','AT2001','AT2005','AT2006','AT2007') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <delete id="deleteByTnoKey" parameterType="java.lang.String"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    delete from EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    where tno = #{id,jdbcType=VARCHAR} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </delete> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="selectDwAll" resultType="java.lang.String"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        select name from T_RM_UNIT  where qname ='应急物资单位' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="selectMaxTno" resultType="java.lang.Integer"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        select  max(tno)  from EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <insert id="add" parameterType="com.steerinfo.ems.temergencymaterials.model.TEmergencymaterials"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    insert into EMS_YJWZ_BASEINFO (tno, gx_code, gx_name, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      yjwz_dd, yjwz_ry, lxdh,wzdl_name, wzlb_name, sbmc_name, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      xh, dw, hsyjz1,hsyjz2, cjr, cjsj,memo, kcl 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      ) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    values (#{tno,jdbcType=DECIMAL}, #{gx_code,jdbcType=VARCHAR}, #{gx_name,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      #{yjwz_dd,jdbcType=VARCHAR}, #{yjwz_ry,jdbcType=VARCHAR}, #{lxdh,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      #{wzdl_name,jdbcType=VARCHAR}, #{wzlb_name,jdbcType=VARCHAR}, #{sbmc_name,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      #{xh,jdbcType=VARCHAR}, #{dw,jdbcType=VARCHAR}, #{hsyjz1,jdbcType=DECIMAL}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      #{hsyjz2,jdbcType=DECIMAL}, #{cjr,jdbcType=VARCHAR}, #{cjsj,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      #{memo,jdbcType=VARCHAR}, #{kcl,jdbcType=DECIMAL}) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+  </insert> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <select id="getGxCodeByGxname" resultType="java.lang.String" parameterType="java.lang.String"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        select id from T_RM_WORKPROC where name = #{gx_name,jdbcType=VARCHAR} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    </select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <update id="batchupdate" parameterType="com.steerinfo.ems.temergencymaterials.model.TEmergencymaterials"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    update EMS_YJWZ_BASEINFO 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    set gx_code = #{gx_code,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      gx_name = #{gx_name,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      yjwz_dd = #{yjwz_dd,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      yjwz_ry = #{yjwz_ry,jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      lxdh = #{lxdh, jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      wzdl_name = #{wzdl_name, jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      wzlb_name = #{wzlb_name, jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      sbmc_name = #{sbmc_name, jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      xh= #{xh, jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      dw= #{dw, jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      hsyjz1= #{hsyjz1, jdbcType=DECIMAL}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      hsyjz2= #{hsyjz2, jdbcType=DECIMAL}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      memo= #{memo, jdbcType=VARCHAR}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      kcl= #{kcl, jdbcType=DECIMAL} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    where tno = #{tno,jdbcType=DECIMAL} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+  </update> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+</mapper> 
			 |