From 209a57aecbf26911f6a3ae0692b51ed0289f5b1a Mon Sep 17 00:00:00 2001 From: wu <731351411@qq.com> Date: 星期四, 14 九月 2023 17:04:56 +0800 Subject: [PATCH] 优化理片笼逻辑 --- springboot-vue3/src/main/java/com/example/springboot/mapper/HomeMapper.java | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/springboot-vue3/src/main/java/com/example/springboot/mapper/HomeMapper.java b/springboot-vue3/src/main/java/com/example/springboot/mapper/HomeMapper.java index 384b18c..3e22d2c 100644 --- a/springboot-vue3/src/main/java/com/example/springboot/mapper/HomeMapper.java +++ b/springboot-vue3/src/main/java/com/example/springboot/mapper/HomeMapper.java @@ -34,11 +34,11 @@ List<StorageCage> selectinout(@Param("task_type") Integer task_type); // 鏌ヨ鏄惁瀛樺湪姝よ鍗� - @Select("select count(*) from storage_cage where order_id=#{orderid} and state=0") + @Select("select count(*) from storage_cage where order_id=#{orderid} and state=1") short SelectOrder(@Param("orderid") String orderid); // @Insert("insert into order_out(orderid) values('#{orderid}')") - @Insert("INSERT INTO `canadames`.`order_out`( `orderid`,`mod_time`) VALUES ( #{orderid},now())") + @Insert("INSERT INTO `canadames`.`order_out`( `order_id`,`state`) VALUES ( #{orderid},0)") void InsertOrder(String orderid); // 鍋滄鎸夊綋鍓嶈鍗曞嚭鐗� @@ -54,12 +54,12 @@ void UpdateTask(@Param("task_type") Integer task_type, @Param("shelf_rack") Integer shelf_rack); // 鎵嬪姩瀹屾垚杩涚墖浠诲姟淇敼绗煎瓙鏁版嵁 - @Update("update storage_cage set state=1 where cell=#{cell} and state=2") - void UpdateCageTask1(@Param("cell") Integer cell); + @Update("update storage_cage set state=1 where cell=#{cell} and glass_id=#{glassid} and state=2") + void UpdateCageTask1(@Param("cell") Integer cell,@Param("glassid") Integer glassid); // 鎵嬪姩瀹屾垚鍑虹墖浠诲姟淇敼绗煎瓙鏁版嵁 - @Update("update storage_cage set state=0,glass_id=null,order_id=null,glasswidth=null,glassheight=null,coating=null where cell=#{cell} and state=2") - void UpdateCageTask2(@Param("cell") Integer cell); + @Update("update storage_cage set state=0,glass_id=null,order_id=null,glasswidth=null,glassheight=null,coating=null where cell=#{cell} and glass_id=#{glassid} and state=3") + void UpdateCageTask2(@Param("cell") Integer cell,@Param("glassid") Integer glassid); //鑾峰彇鎶ヨ淇℃伅 @Select("select id,content,timeon as timeons,endTime from alarmmg where endTime is null") -- Gitblit v1.8.0