From c13207a19a92c845fcb8c356e01f073142d9084e Mon Sep 17 00:00:00 2001
From: ZengTao <2773468879@qq.com>
Date: 星期五, 19 一月 2024 14:32:42 +0800
Subject: [PATCH] 测试后代码更新

---
 springboot-vue3/src/main/java/com/example/springboot/mapper/SpianMapper.java |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/springboot-vue3/src/main/java/com/example/springboot/mapper/SpianMapper.java b/springboot-vue3/src/main/java/com/example/springboot/mapper/SpianMapper.java
index 612e27a..20a4424 100644
--- a/springboot-vue3/src/main/java/com/example/springboot/mapper/SpianMapper.java
+++ b/springboot-vue3/src/main/java/com/example/springboot/mapper/SpianMapper.java
@@ -18,8 +18,8 @@
     @Select("select a.cage,FrameBarcode,COUNT(if(a.order_id=#{orderids},a.order_id,null))as orderid,b.shu,c.shu2,a.cell,min(a.state)as state1,max(a.state)as state2,disabled,FrameBarcode from storage_cage a left join (select COUNT(*)shu,cage from storage_cage  where order_id=#{orderids} GROUP BY cage)as b on a.cage=b.cage left join(select cage ,COUNT(glass_id)as shu2 from storage_cage GROUP BY cage)c  on a.cage=c.cage where (order_id=#{orderids} or ''='') GROUP BY cage,cell HAVING state1=0 ORDER BY (FrameBarcode=#{Fbarcode} or ''='') desc,shu desc,shu2,state2 asc,cage asc;")
     List<StorageCage> selectAll(String orderids,String Fbarcode);
     //浼樺厛鍒ゆ柇涓�娆℃槸鍚︽湁鍚岄摑妗嗙殑绌轰綅
-    @Select("select *,min(state) state1 from storage_cage  GROUP BY cage,cell HAVING state1=0 and  FrameBarcode=#{FrameBarcode} LIMIT 1;")
-    List<StorageCage> selectAllFbarcode(String Fbarcode);
+    @Select("select *,min(state) state1 from storage_cage where width>=(#{width}+#{width2})  GROUP BY cage,cell HAVING state1=0 and  FrameBarcode=#{Fbarcode} ORDER BY width desc LIMIT 1;")
+    List<StorageCage> selectAllFbarcode(String Fbarcode,double width,double width2);
     // 鑾峰彇鍒ゆ柇璇ユ牸瀛愭槸鍚﹂渶瑕佹妸澶栫墖鎺ㄥ叆鍐呯墖浣嶇疆
     @Select("select state from storage_cage where  cage=#{cage} and cell=#{cell} and tier=1;")
     int selectcell(int cage, int cell);
@@ -232,4 +232,7 @@
     //鍒ゆ柇鐜荤拑鏄惁绂佺敤
     @Select(" select disabled from storage_cage where glass_id=#{glassid} limit 1;")
     int SelectCageGlassState(String glassid);
+    //鍒ゆ柇姹囨姤鐨刬d鏄惁姝g‘
+    @Select("SELECT count(*) FROM `storage_cage` where state!=0 and state!=1 and glass_id=#{glassid}")
+    int SelectHB(String glassid);
 }
\ No newline at end of file

--
Gitblit v1.8.0