From bcd4c6fc21eef7abf7e28661bd4f9e1f5cdd2a61 Mon Sep 17 00:00:00 2001
From: chenlu <1320612696@qq.com>
Date: 星期一, 09 十二月 2024 16:37:29 +0800
Subject: [PATCH] 补片新增修改会出现重复编号的问题

---
 north-glass-erp/src/main/resources/mapper/mm/MaterialStore.xml |   17 +++++++++++++++++
 1 files changed, 17 insertions(+), 0 deletions(-)

diff --git a/north-glass-erp/src/main/resources/mapper/mm/MaterialStore.xml b/north-glass-erp/src/main/resources/mapper/mm/MaterialStore.xml
index 51ffa8c..42b8df8 100644
--- a/north-glass-erp/src/main/resources/mapper/mm/MaterialStore.xml
+++ b/north-glass-erp/src/main/resources/mapper/mm/MaterialStore.xml
@@ -17,9 +17,26 @@
                 and m.type regexp #{materialStore.type}
             </if>
         </where>
+        order by m.id desc
         limit #{offset},#{pageSize};
     </select>
 
+    <select id="getSelectMaterialStores">
+        select
+        *
+        from
+        mm.material_store m
+        <where>
+            <if test="materialStore.id != null and materialStore.id != ''">
+                and m.id regexp #{materialStore.id}
+            </if>
+            <if test="materialStore.type != null and materialStore.type != ''">
+                and m.type regexp #{materialStore.type}
+            </if>
+        </where>
+        order by m.id desc
+    </select>
+
     <select id="getSelectMaterialStoreById">
         select * from mm.material_store m where id=#{id}
     </select>

--
Gitblit v1.8.0