ソースを参照

1.增加字典和标准药品

zjh 2 年 前
コミット
06b5fc8476
26 ファイル変更451 行追加0 行削除
  1. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/dic/TDicBase.java
  2. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/dic/TDicMapping.java
  3. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/dic/TDicStandard.java
  4. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/drug/BStandardMat.java
  5. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/drug/TStandardMaterialMapping.java
  6. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/common/utils/CreateCode.java
  7. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/dic/TDicBaseController.java
  8. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/dic/TDicMappingController.java
  9. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/dic/TDicStandardController.java
  10. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/drug/BStandardMatController.java
  11. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/drug/TStandardMaterialMappingController.java
  12. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/dic/TDicBaseMapper.java
  13. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/dic/TDicMappingMapper.java
  14. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/dic/TDicStandardMapper.java
  15. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/drug/BStandardMatMapper.java
  16. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/drug/TStandardMaterialMappingMapper.java
  17. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/dic/TDicBaseService.java
  18. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/dic/TDicMappingService.java
  19. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/dic/TDicStandardService.java
  20. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/drug/BStandardMatService.java
  21. BIN
      cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/drug/TStandardMaterialMappingService.java
  22. 111 0
      cbkj_web_parameter/src/main/resources/mappers/dic/TDicBaseMapper.xml
  23. 71 0
      cbkj_web_parameter/src/main/resources/mappers/dic/TDicMappingMapper.xml
  24. 99 0
      cbkj_web_parameter/src/main/resources/mappers/dic/TDicStandardMapper.xml
  25. 75 0
      cbkj_web_parameter/src/main/resources/mappers/drug/BStandardMatMapper.xml
  26. 95 0
      cbkj_web_parameter/src/main/resources/mappers/drug/TStandardMaterialMappingMapper.xml

BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/dic/TDicBase.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/dic/TDicMapping.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/dic/TDicStandard.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/drug/BStandardMat.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/beans/drug/TStandardMaterialMapping.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/common/utils/CreateCode.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/dic/TDicBaseController.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/dic/TDicMappingController.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/dic/TDicStandardController.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/drug/BStandardMatController.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/controller/drug/TStandardMaterialMappingController.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/dic/TDicBaseMapper.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/dic/TDicMappingMapper.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/dic/TDicStandardMapper.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/drug/BStandardMatMapper.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/mapper/drug/TStandardMaterialMappingMapper.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/dic/TDicBaseService.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/dic/TDicMappingService.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/dic/TDicStandardService.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/drug/BStandardMatService.java


BIN
cbkj_web_parameter/src/main/java/com/jiuzhekan/cbkj/service/drug/TStandardMaterialMappingService.java


+ 111 - 0
cbkj_web_parameter/src/main/resources/mappers/dic/TDicBaseMapper.xml

@@ -0,0 +1,111 @@
+<?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.jiuzhekan.cbkj.mapper.dic.TDicBaseMapper">
+
+    <resultMap id="BaseResultMap" type="com.jiuzhekan.cbkj.beans.dic.TDicBase">
+        <id column="dic_id" jdbcType="VARCHAR"  property="dicId" />
+        <result column="dic_code" jdbcType="VARCHAR" property="dicCode" />
+        <result column="dic_name" jdbcType="VARCHAR" property="dicName" />
+        <result column="parent_id" jdbcType="VARCHAR" property="parentId" />
+        <result column="dic_desc" jdbcType="VARCHAR" property="dicDesc" />
+        <result column="sort" jdbcType="VARCHAR" property="sort" />
+        <result column="app_id" jdbcType="VARCHAR" property="appId" />
+        <result column="ins_code" jdbcType="VARCHAR" property="insCode" />
+        <result column="dept_id" jdbcType="VARCHAR" property="deptId" />
+        <result column="pha_id" jdbcType="VARCHAR" property="phaId" />
+        <result column="create_date" jdbcType="TIMESTAMP" property="createDate" />
+        <result column="create_user" jdbcType="VARCHAR" property="createUser" />
+        <result column="create_user_name" jdbcType="VARCHAR" property="createUserName" />
+        <result column="is_enable" jdbcType="VARCHAR" property="isEnable" />
+    </resultMap>
+
+
+    <sql id="Base_Column_List">
+    dic_id,dic_code,dic_name,parent_id,dic_desc,sort,app_id,ins_code,dept_id,pha_id,create_date,create_user,create_user_name,is_enable
+    </sql>
+
+    <delete id="deleteByPrimaryKey" parameterType="TDicBase">
+        delete from t_dic_base where dic_id = #{ dicId }
+    </delete>
+
+    <delete id="deleteBylist" parameterType="ArrayList">
+        delete from t_dic_base where dic_id in
+        <foreach collection="array" item="item" open="(" separator="," close=")">
+        #{item}
+        </foreach>
+    </delete>
+
+    <insert id="insert"  parameterType="TDicBase">
+        insert into t_dic_base (<include refid="Base_Column_List" />) values
+        (#{dicId},#{dicCode},#{dicName},#{parentId},#{dicDesc},#{sort},#{appId},#{insCode},#{deptId},#{phaId},#{createDate},#{createUser},#{createUserName},#{isEnable})
+    </insert>
+
+    <insert id="insertList" parameterType="List">
+        insert into t_dic_base (<include refid="Base_Column_List" />) values
+        <foreach collection="list" item="item" index="index" separator="," >
+            (#{item.dicId},#{item.dicCode},#{item.dicName},#{item.parentId},#{item.dicDesc},#{item.sort},#{item.appId},#{item.insCode},#{item.deptId},#{item.phaId},#{item.createDate},#{item.createUser},#{item.createUserName},#{item.isEnable})
+        </foreach>
+    </insert>
+
+    <update id="updateByPrimaryKey" parameterType="TDicBase">
+        update t_dic_base
+        <set>
+             <if test="dicCode != null">
+                dic_code = #{ dicCode },
+             </if>
+             <if test="dicName != null">
+                dic_name = #{ dicName },
+             </if>
+             <if test="parentId != null">
+                parent_id = #{ parentId },
+             </if>
+             <if test="dicDesc != null">
+                dic_desc = #{ dicDesc },
+             </if>
+             <if test="sort != null">
+                sort = #{ sort },
+             </if>
+             <if test="appId != null">
+                app_id = #{ appId },
+             </if>
+             <if test="insCode != null">
+                ins_code = #{ insCode },
+             </if>
+             <if test="deptId != null">
+                dept_id = #{ deptId },
+             </if>
+             <if test="phaId != null">
+                pha_id = #{ phaId },
+             </if>
+             <if test="createDate != null">
+                create_date = #{ createDate },
+             </if>
+             <if test="createUser != null">
+                create_user = #{ createUser },
+             </if>
+             <if test="createUserName != null">
+                create_user_name = #{ createUserName },
+             </if>
+             <if test="isEnable != null">
+                is_enable = #{ isEnable },
+             </if>
+        </set>
+        where dic_id = #{ dicId }
+    </update>
+
+    <select id="getObjectById" resultMap="BaseResultMap" parameterType="String">
+        select <include refid="Base_Column_List" />
+        from t_dic_base where dic_id = #{dicId}
+    </select>
+
+    <select id="getPageListByObj" parameterType="TDicBase" resultMap="BaseResultMap">
+        SELECT dic_id,dic_code,dic_name,parent_id,dic_desc,sort,app_id,ins_code,dept_id,pha_id,create_date,create_user,create_user_name,is_enable
+        from t_dic_base
+        <where>
+            <if test=" dicName != null and dicName!='' ">
+                and dic_name like CONCAT('%',trim(#{dicName}),'%')
+            </if>
+        </where>
+    </select>
+
+</mapper>

+ 71 - 0
cbkj_web_parameter/src/main/resources/mappers/dic/TDicMappingMapper.xml

@@ -0,0 +1,71 @@
+<?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.jiuzhekan.cbkj.mapper.dic.TDicMappingMapper">
+
+    <resultMap id="BaseResultMap" type="com.jiuzhekan.cbkj.beans.dic.TDicMapping">
+        <id column="id" jdbcType="VARCHAR"  property="id" />
+        <result column="dic_id" jdbcType="VARCHAR" property="dicId" />
+        <result column="stan_id" jdbcType="VARCHAR" property="stanId" />
+        <result column="stan_type" jdbcType="VARCHAR" property="stanType" />
+    </resultMap>
+
+
+    <sql id="Base_Column_List">
+    id,dic_id,stan_id,stan_type
+    </sql>
+
+    <delete id="deleteByPrimaryKey" parameterType="TDicMapping">
+        delete from t_dic_mapping where id = #{ id }
+    </delete>
+
+    <delete id="deleteBylist" parameterType="ArrayList">
+        delete from t_dic_mapping where id in
+        <foreach collection="array" item="item" open="(" separator="," close=")">
+        #{item}
+        </foreach>
+    </delete>
+
+    <insert id="insert"  parameterType="TDicMapping">
+        insert into t_dic_mapping (<include refid="Base_Column_List" />) values
+        (#{id},#{dicId},#{stanId},#{stanType})
+    </insert>
+
+    <insert id="insertList" parameterType="List">
+        insert into t_dic_mapping (<include refid="Base_Column_List" />) values
+        <foreach collection="list" item="item" index="index" separator="," >
+            (#{item.id},#{item.dicId},#{item.stanId},#{item.stanType})
+        </foreach>
+    </insert>
+
+    <update id="updateByPrimaryKey" parameterType="TDicMapping">
+        update t_dic_mapping
+        <set>
+             <if test="dicId != null">
+                dic_id = #{ dicId },
+             </if>
+             <if test="stanId != null">
+                stan_id = #{ stanId },
+             </if>
+             <if test="stanType != null">
+                stan_type = #{ stanType },
+             </if>
+        </set>
+        where id = #{ id }
+    </update>
+
+    <select id="getObjectById" resultMap="BaseResultMap" parameterType="String">
+        select <include refid="Base_Column_List" />
+        from t_dic_mapping where id = #{id}
+    </select>
+
+    <select id="getPageListByObj" parameterType="TDicMapping" resultMap="BaseResultMap">
+        SELECT id,dic_id,stan_id,stan_type
+        from t_dic_mapping
+        <where>
+            <if test=" name != null and name!='' ">
+                and name like CONCAT('%',trim(#{name}),'%')
+            </if>
+        </where>
+    </select>
+
+</mapper>

+ 99 - 0
cbkj_web_parameter/src/main/resources/mappers/dic/TDicStandardMapper.xml

@@ -0,0 +1,99 @@
+<?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.jiuzhekan.cbkj.mapper.dic.TDicStandardMapper">
+
+    <resultMap id="BaseResultMap" type="com.jiuzhekan.cbkj.beans.dic.TDicStandard">
+        <id column="stan_id" jdbcType="VARCHAR"  property="stanId" />
+        <result column="stan_code" jdbcType="VARCHAR" property="stanCode" />
+        <result column="stan_name" jdbcType="VARCHAR" property="stanName" />
+        <result column="parent_id" jdbcType="VARCHAR" property="parentId" />
+        <result column="stan_desc" jdbcType="VARCHAR" property="stanDesc" />
+        <result column="stan_type" jdbcType="VARCHAR" property="stanType" />
+        <result column="sort" jdbcType="VARCHAR" property="sort" />
+        <result column="create_date" jdbcType="TIMESTAMP" property="createDate" />
+        <result column="create_user" jdbcType="VARCHAR" property="createUser" />
+        <result column="create_user_name" jdbcType="VARCHAR" property="createUserName" />
+        <result column="is_enable" jdbcType="VARCHAR" property="isEnable" />
+    </resultMap>
+
+
+    <sql id="Base_Column_List">
+    stan_id,stan_code,stan_name,parent_id,stan_desc,stan_type,sort,create_date,create_user,create_user_name,is_enable
+    </sql>
+
+    <delete id="deleteByPrimaryKey" parameterType="TDicStandard">
+        delete from t_dic_standard where stan_id = #{ stanId }
+    </delete>
+
+    <delete id="deleteBylist" parameterType="ArrayList">
+        delete from t_dic_standard where stan_id in
+        <foreach collection="array" item="item" open="(" separator="," close=")">
+        #{item}
+        </foreach>
+    </delete>
+
+    <insert id="insert"  parameterType="TDicStandard">
+        insert into t_dic_standard (<include refid="Base_Column_List" />) values
+        (#{stanId},#{stanCode},#{stanName},#{parentId},#{stanDesc},#{stanType},#{sort},#{createDate},#{createUser},#{createUserName},#{isEnable})
+    </insert>
+
+    <insert id="insertList" parameterType="List">
+        insert into t_dic_standard (<include refid="Base_Column_List" />) values
+        <foreach collection="list" item="item" index="index" separator="," >
+            (#{item.stanId},#{item.stanCode},#{item.stanName},#{item.parentId},#{item.stanDesc},#{item.stanType},#{item.sort},#{item.createDate},#{item.createUser},#{item.createUserName},#{item.isEnable})
+        </foreach>
+    </insert>
+
+    <update id="updateByPrimaryKey" parameterType="TDicStandard">
+        update t_dic_standard
+        <set>
+             <if test="stanCode != null">
+                stan_code = #{ stanCode },
+             </if>
+             <if test="stanName != null">
+                stan_name = #{ stanName },
+             </if>
+             <if test="parentId != null">
+                parent_id = #{ parentId },
+             </if>
+             <if test="stanDesc != null">
+                stan_desc = #{ stanDesc },
+             </if>
+             <if test="stanType != null">
+                stan_type = #{ stanType },
+             </if>
+             <if test="sort != null">
+                sort = #{ sort },
+             </if>
+             <if test="createDate != null">
+                create_date = #{ createDate },
+             </if>
+             <if test="createUser != null">
+                create_user = #{ createUser },
+             </if>
+             <if test="createUserName != null">
+                create_user_name = #{ createUserName },
+             </if>
+             <if test="isEnable != null">
+                is_enable = #{ isEnable },
+             </if>
+        </set>
+        where stan_id = #{ stanId }
+    </update>
+
+    <select id="getObjectById" resultMap="BaseResultMap" parameterType="String">
+        select <include refid="Base_Column_List" />
+        from t_dic_standard where stan_id = #{ stanId }
+    </select>
+
+    <select id="getPageListByObj" parameterType="TDicStandard" resultMap="BaseResultMap">
+        SELECT stan_id,stan_code,stan_name,parent_id,stan_desc,stan_type,sort,create_date,create_user,create_user_name,is_enable
+        from t_dic_standard
+        <where>
+            <if test=" stanName != null and stanName!='' ">
+                and stan_name like CONCAT('%',trim(#{stanName}),'%')
+            </if>
+        </where>
+    </select>
+
+</mapper>

+ 75 - 0
cbkj_web_parameter/src/main/resources/mappers/drug/BStandardMatMapper.xml

@@ -0,0 +1,75 @@
+<?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.jiuzhekan.cbkj.mapper.drug.BStandardMatMapper">
+
+    <resultMap id="BaseResultMap" type="com.jiuzhekan.cbkj.beans.drug.BStandardMat">
+        <id column="s_id" jdbcType="VARCHAR"  property="sId" />
+        <result column="s_mat_code" jdbcType="VARCHAR" property="sMatCode" />
+        <result column="s_mat_name" jdbcType="VARCHAR" property="sMatName" />
+        <result column="s_mat_class" jdbcType="VARCHAR" property="sMatClass" />
+        <result column="s_mat_type" jdbcType="VARCHAR" property="sMatType" />
+    </resultMap>
+
+
+    <sql id="Base_Column_List">
+    s_id,s_mat_code,s_mat_name,s_mat_class,s_mat_type
+    </sql>
+
+    <delete id="deleteByPrimaryKey" parameterType="BStandardMat">
+        delete from b_standard_mat where s_id = #{ sId }
+    </delete>
+
+    <delete id="deleteBylist" parameterType="ArrayList">
+        delete from b_standard_mat where s_id in
+        <foreach collection="array" item="item" open="(" separator="," close=")">
+        #{item}
+        </foreach>
+    </delete>
+
+    <insert id="insert"  parameterType="BStandardMat">
+        insert into b_standard_mat (<include refid="Base_Column_List" />) values
+        (#{sId},#{sMatCode},#{sMatName},#{sMatClass},#{sMatType})
+    </insert>
+
+    <insert id="insertList" parameterType="List">
+        insert into b_standard_mat (<include refid="Base_Column_List" />) values
+        <foreach collection="list" item="item" index="index" separator="," >
+            (#{item.sId},#{item.sMatCode},#{item.sMatName},#{item.sMatClass},#{item.sMatType})
+        </foreach>
+    </insert>
+
+    <update id="updateByPrimaryKey" parameterType="BStandardMat">
+        update b_standard_mat
+        <set>
+             <if test="sMatCode != null">
+                s_mat_code = #{ sMatCode },
+             </if>
+             <if test="sMatName != null">
+                s_mat_name = #{ sMatName },
+             </if>
+             <if test="sMatClass != null">
+                s_mat_class = #{ sMatClass },
+             </if>
+             <if test="sMatType != null">
+                s_mat_type = #{ sMatType },
+             </if>
+        </set>
+        where s_id = #{ sId }
+    </update>
+
+    <select id="getObjectById" resultMap="BaseResultMap" parameterType="String">
+        select <include refid="Base_Column_List" />
+        from b_standard_mat where s_id = #{ sId }
+    </select>
+
+    <select id="getPageListByObj" parameterType="BStandardMat" resultMap="BaseResultMap">
+        SELECT s_id,s_mat_code,s_mat_name,s_mat_class,s_mat_type
+        from b_standard_mat
+        <where>
+            <if test=" sMatName != null and sMatName!='' ">
+                and s_mat_name like CONCAT('%',trim(#{sMatName}),'%')
+            </if>
+        </where>
+    </select>
+
+</mapper>

+ 95 - 0
cbkj_web_parameter/src/main/resources/mappers/drug/TStandardMaterialMappingMapper.xml

@@ -0,0 +1,95 @@
+<?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.jiuzhekan.cbkj.mapper.drug.TStandardMaterialMappingMapper">
+
+    <resultMap id="BaseResultMap" type="com.jiuzhekan.cbkj.beans.drug.TStandardMaterialMapping">
+        <id column="id" jdbcType="VARCHAR"  property="id" />
+        <result column="s_id" jdbcType="VARCHAR" property="sId" />
+        <result column="s_mat_name" jdbcType="VARCHAR" property="sMatName" />
+        <result column="s_mat_code" jdbcType="VARCHAR" property="sMatCode" />
+        <result column="s_mat_type" jdbcType="VARCHAR" property="sMatType" />
+        <result column="drug_id" jdbcType="VARCHAR" property="drugId" />
+        <result column="mat_id" jdbcType="VARCHAR" property="matId" />
+        <result column="create_date" jdbcType="TIMESTAMP" property="createDate" />
+        <result column="create_user" jdbcType="VARCHAR" property="createUser" />
+        <result column="create_user_name" jdbcType="VARCHAR" property="createUserName" />
+    </resultMap>
+
+
+    <sql id="Base_Column_List">
+    id,s_id,s_mat_name,s_mat_code,s_mat_type,drug_id,mat_id,create_date,create_user,create_user_name
+    </sql>
+
+    <delete id="deleteByPrimaryKey" parameterType="TStandardMaterialMapping">
+        delete from t_standard_material_mapping where id = #{ id }
+    </delete>
+
+    <delete id="deleteBylist" parameterType="ArrayList">
+        delete from t_standard_material_mapping where id in
+        <foreach collection="array" item="item" open="(" separator="," close=")">
+        #{item}
+        </foreach>
+    </delete>
+
+    <insert id="insert"  parameterType="TStandardMaterialMapping">
+        insert into t_standard_material_mapping (<include refid="Base_Column_List" />) values
+        (#{id},#{sId},#{sMatName},#{sMatCode},#{sMatType},#{drugId},#{matId},#{createDate},#{createUser},#{createUserName})
+    </insert>
+
+    <insert id="insertList" parameterType="List">
+        insert into t_standard_material_mapping (<include refid="Base_Column_List" />) values
+        <foreach collection="list" item="item" index="index" separator="," >
+            (#{item.id},#{item.sId},#{item.sMatName},#{item.sMatCode},#{item.sMatType},#{item.drugId},#{item.matId},#{item.createDate},#{item.createUser},#{item.createUserName})
+        </foreach>
+    </insert>
+
+    <update id="updateByPrimaryKey" parameterType="TStandardMaterialMapping">
+        update t_standard_material_mapping
+        <set>
+             <if test="sId != null">
+                s_id = #{ sId },
+             </if>
+             <if test="sMatName != null">
+                s_mat_name = #{ sMatName },
+             </if>
+             <if test="sMatCode != null">
+                s_mat_code = #{ sMatCode },
+             </if>
+             <if test="sMatType != null">
+                s_mat_type = #{ sMatType },
+             </if>
+             <if test="drugId != null">
+                drug_id = #{ drugId },
+             </if>
+             <if test="matId != null">
+                mat_id = #{ matId },
+             </if>
+             <if test="createDate != null">
+                create_date = #{ createDate },
+             </if>
+             <if test="createUser != null">
+                create_user = #{ createUser },
+             </if>
+             <if test="createUserName != null">
+                create_user_name = #{ createUserName },
+             </if>
+        </set>
+        where id = #{ id }
+    </update>
+
+    <select id="getObjectById" resultMap="BaseResultMap" parameterType="String">
+        select <include refid="Base_Column_List" />
+        from t_standard_material_mapping where id = #{id}
+    </select>
+
+    <select id="getPageListByObj" parameterType="TStandardMaterialMapping" resultMap="BaseResultMap">
+        SELECT id,s_id,s_mat_name,s_mat_code,s_mat_type,drug_id,mat_id,create_date,create_user,create_user_name
+        from t_standard_material_mapping
+        <where>
+            <if test=" name != null and name!='' ">
+                and name like CONCAT('%',trim(#{name}),'%')
+            </if>
+        </where>
+    </select>
+
+</mapper>