From d560ea0f6d13c6bc309cd41603fe4bc8914a2c12 Mon Sep 17 00:00:00 2001
From: xiejun <xj@2023>
Date: 星期四, 28 九月 2023 11:31:15 +0800
Subject: [PATCH] 集成接口参数配置修改
---
Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CodeCLassifyMapper.xml | 36 ++++++++++++++++++++++++++----------
1 files changed, 26 insertions(+), 10 deletions(-)
diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CodeCLassifyMapper.xml b/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CodeCLassifyMapper.xml
index 5ac72c8..40dfb07 100644
--- a/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CodeCLassifyMapper.xml
+++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CodeCLassifyMapper.xml
@@ -39,11 +39,16 @@
<result column="CODERESEMBLERULEOID" property="codeResembleRuleOid"/>
<result column="TENANT_ID" property="tenantId"/>
</resultMap>
+
<sql id="tableName">
pl_code_classify
</sql>
+
<select id="selectPlCodeClassifyPage" resultMap="plCodeClassifyResultMap">
- select * from PL_CODE_CLASSIFY where is_deleted = 0
+ select * from PL_CODE_CLASSIFY where
+ <if test="tenantId != null and tenantId != ''">
+ tenant_id = #{tenantId}
+ </if>
</select>
<select id="selectAllLevelChildOid" resultType="java.util.HashMap">
@@ -101,7 +106,7 @@
codeclassify0.tenant_id = #{tenantId}
</if>
</where>
- order by id asc
+ order by lastmodifytime asc
</select>
<select id="selectAllLevelChildHasPath" resultMap="plCodeClassifyResultMap">
@@ -172,8 +177,14 @@
</select>
<select id="selectAllLevelParentByOid" resultType="java.util.HashMap">
- select oid,
- level from pl_code_classify start with oid= #{oid} connect by prior PARENTCODECLASSIFYOID = oid
+ select b.oid as oid,level from
+ pl_code_classify b
+ join (select oid
+ from pl_code_classify
+ start with oid = #{oid}
+ connect by oid = prior PARENTCODECLASSIFYOID) a on b.oid = a.OID
+ start with b.PARENTCODECLASSIFYOID is null
+ connect by prior b.oid = b.PARENTCODECLASSIFYOID
</select>
<select id="getIdPathToNamePathByParentId" resultMap="plCodeClassifyResultMap">
@@ -236,7 +247,6 @@
SYS_CONNECT_BY_PATH(id, '#') as paths
</otherwise>
</choose>
-
from pl_code_classify plcodeclassify
START WITH parentCodeClassifyOid is null
CONNECT BY PRIOR OID = parentCodeClassifyOid) codeclassify0
@@ -302,7 +312,7 @@
<if test="tenantId != null and tenantId != ''">
and codeclassify0.tenant_id = #{tenantId}
</if>
- order by id asc
+ order by lastmodifytime desc
</select>
<select id="selectClassifyByKeyAndReseRel" resultMap="plCodeClassifyResultMap">
@@ -358,12 +368,12 @@
<if test="parentOid == null or parentOid == ''">
and codeclassify0.parentcodeclassifyoid is null
</if>
-
<if test="tenantId != null and tenantId != ''">
- codeclassify0.tenant_id = #{tenantId}
+ and codeclassify0.tenant_id = #{tenantId}
</if>
order by id asc
</select>
+
<select id="getRMLibByName" resultMap="plCodeClassifyResultMap">
select codeclassify0.OWNER as owner,
codeclassify0.BTMTYPEID as btmtypeid,
@@ -404,7 +414,7 @@
</foreach>
</if>
<if test="tenantId != null and tenantId != ''">
- codeclassify0.tenant_id = #{tenantId}
+ and codeclassify0.tenant_id = #{tenantId}
</if>
order by id asc
</select>
@@ -444,7 +454,6 @@
<if test="desc != null">
and codeclassify0.DESCRIPTION = #{desc}
</if>
-
<if test="tenantId != null and tenantId != ''">
and codeclassify0.tenant_id = #{tenantId}
</if>
@@ -507,4 +516,11 @@
</foreach>
;END;
</update>
+
+ <select id="selectAllParents" resultMap="plCodeClassifyResultMap">
+ select * from PL_CODE_CLASSIFY p
+ start with p.OID =#{oid}
+ connect by p.oid = prior p.PARENTCODECLASSIFYOID
+ </select>
+
</mapper>
--
Gitblit v1.9.3