From 5cd4558fb1a7178653d77e1a982e6f26d06b5db5 Mon Sep 17 00:00:00 2001
From: Lius <Lius2225@163.com>
Date: 星期一, 31 三月 2025 17:39:00 +0800
Subject: [PATCH] 中心综合利用率趋势接口

---
 lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/mapper/xml/PermissionStreamNewMapper.xml |   35 ++++++++++++++++++-----------------
 1 files changed, 18 insertions(+), 17 deletions(-)

diff --git a/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/mapper/xml/PermissionStreamNewMapper.xml b/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/mapper/xml/PermissionStreamNewMapper.xml
index de844de..e7552dc 100644
--- a/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/mapper/xml/PermissionStreamNewMapper.xml
+++ b/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/mapper/xml/PermissionStreamNewMapper.xml
@@ -5,10 +5,11 @@
         SELECT DISTINCT
             mix.id,
             mix.tree_code 'code',
-                mix.name,
+                mix.tree_name 'name',
             mix.parent_id,
             mix.tree_type AS 'type',
-                mix.extend
+                mix.extend,
+                mix.create_time
         FROM
             nc_product_mix mix -- 杩炴帴鏉冮檺琛紝绛涢�夐儴闂ㄧ浉鍏宠褰�
                 LEFT JOIN nc_permission_stream_new nps_depart ON mix.id = nps_depart.business_id
@@ -25,22 +26,22 @@
                 AND nps_user.delete_flag = '0'
         WHERE
             nps_depart.business_id IS NOT NULL
-          AND nps_user.business_id IS NOT NULL;
+          AND nps_user.business_id IS NOT NULL
+        order by mix.tree_type, mix.create_time asc
     </select>
     <select id="loadProductMixAll" resultType="org.jeecg.modules.dnc.entity.ProductMix">
-        SELECT DISTINCT
-        mix.id,
-        mix.tree_code 'code',
-        mix.name,
-        mix.parent_id,
-        mix.tree_type AS 'type',
-        mix.extend
-        FROM
-        nc_product_mix mix -- 杩炴帴鏉冮檺琛紝绛涢�夐儴闂ㄧ浉鍏宠褰�
-        LEFT JOIN nc_permission_stream_new nps_user ON mix.id = nps_user.business_id
-        AND nps_user.user_id = #{userId}
-        AND nps_user.delete_flag = '0'
-        WHERE
-         nps_user.business_id IS NOT NULL;
+        SELECT DISTINCT mix.id,
+                        mix.tree_code    'code',
+                        mix.tree_name    'name',
+                        mix.parent_id,
+                        mix.tree_type AS 'type',
+                        mix.extend,
+                        mix.create_time
+        FROM nc_product_mix mix -- 杩炴帴鏉冮檺琛紝绛涢�夐儴闂ㄧ浉鍏宠褰�
+                 LEFT JOIN nc_permission_stream_new nps_user ON mix.id = nps_user.business_id
+            AND nps_user.user_id = #{userId}
+            AND nps_user.delete_flag = '0'
+        WHERE nps_user.business_id IS NOT NULL
+        order by mix.tree_type, mix.create_time asc
     </select>
 </mapper>

--
Gitblit v1.9.3