From 367c66e0ab339e15d6ad881ace683cec7e11f2f7 Mon Sep 17 00:00:00 2001 From: yuxc <653031404@qq.com> Date: 星期二, 30 五月 2023 17:34:36 +0800 Subject: [PATCH] 1、主要完成传入业务类型与basemodel进行插入。 2、完成传入业务类型、oid进行查询返回list<basemodel> --- Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CommonsMapper.xml | 20 +++++++++++++++++++- 1 files changed, 19 insertions(+), 1 deletions(-) diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CommonsMapper.xml b/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CommonsMapper.xml index 8f62d59..7aee99d 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CommonsMapper.xml +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CommonsMapper.xml @@ -6,7 +6,7 @@ <select id="selectByCount" resultType="java.util.Map"> select COUNT(w.OID) count from ${tableName} w - join PL_CODE_ALLCODE c on w.OID = c.CREATECODEOID + join PL_CODE_ALLCODE c on w.OID = c.CREATECODEOID where c.CREATECODEBTM = #{btm} and c.CODERULEOID = #{oid} and w.LASTR = '1' @@ -18,5 +18,23 @@ ${inSql} </select> + <select id="selectBySql" resultType="java.util.Map"> + ${inSql} + </select> + + <insert id="insertByBaseModel" parameterType="java.util.Map"> + insert into ${tableName} + ( + <foreach collection="columnMap" item="value" index="key" separator=","> + ${key} + </foreach> + ) + <foreach collection="mapList" item="columnMap" separator=" union all "> + select <foreach collection="columnMap" item="value" index="key" separator=","> + #{value} + </foreach> + from dual + </foreach> + </insert> </mapper> -- Gitblit v1.9.3