From 6623eb184a335f55c0da2a8deec65eb43b75bd74 Mon Sep 17 00:00:00 2001
From: wu <731351411@qq.com>
Date: 星期四, 07 三月 2024 09:36:34 +0800
Subject: [PATCH] 更新代码

---
 springboot-vue3/src/main/java/com/example/springboot/mapper/AlbaniaMapper.java |   44 ++++++++++++++
 springboot-vue3/src/main/java/com/example/springboot/entity/flowcard.java      |   19 ++++++
 springboot-vue3/src/main/resources/JsonFile/Albania.json                       |   51 +++++++++++++++++
 springboot-vue3/src/main/java/com/example/springboot/entity/glassinfo.java     |   25 ++++++++
 4 files changed, 139 insertions(+), 0 deletions(-)

diff --git a/springboot-vue3/src/main/java/com/example/springboot/entity/flowcard.java b/springboot-vue3/src/main/java/com/example/springboot/entity/flowcard.java
new file mode 100644
index 0000000..0d6a010
--- /dev/null
+++ b/springboot-vue3/src/main/java/com/example/springboot/entity/flowcard.java
@@ -0,0 +1,19 @@
+package com.example.springboot.entity;
+
+import java.util.Date;
+
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import lombok.Data;
+
+@Data
+@TableName("`flowcard`")
+public class flowcard {
+  private Integer id;// 鑷id
+  private String flowcard;// 娴佺▼鍗d
+  private Integer number;// 鐜荤拑鏁伴噺
+  private Integer line;// 浠诲姟璺嚎
+  private Integer state;// 鐘舵��
+ 
+
+}
diff --git a/springboot-vue3/src/main/java/com/example/springboot/entity/glassinfo.java b/springboot-vue3/src/main/java/com/example/springboot/entity/glassinfo.java
new file mode 100644
index 0000000..568facc
--- /dev/null
+++ b/springboot-vue3/src/main/java/com/example/springboot/entity/glassinfo.java
@@ -0,0 +1,25 @@
+package com.example.springboot.entity;
+
+import java.util.Date;
+
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import lombok.Data;
+
+@Data
+@TableName("`glassinfo`")
+public class glassinfo {
+  private Integer id;// 鑷id
+  private String flowcard;// 娴佺▼鍗d
+  private Integer glasstype;// 鐜荤拑绫诲瀷
+  private Integer mateid;// 閰嶇墖id
+  private Integer glassid;// 鐜荤拑id
+  private Integer tier;// 灞�
+  private String films;// 鑶滅郴
+  private Double width;// 瀹�
+  private Double height;// 楂�
+  private String thickness;// 鍘�
+  private Integer number;// 鏁伴噺
+  private Integer finishnumber;// 瀹屾垚鏁伴噺
+
+}
diff --git a/springboot-vue3/src/main/java/com/example/springboot/mapper/AlbaniaMapper.java b/springboot-vue3/src/main/java/com/example/springboot/mapper/AlbaniaMapper.java
new file mode 100644
index 0000000..e33d0bb
--- /dev/null
+++ b/springboot-vue3/src/main/java/com/example/springboot/mapper/AlbaniaMapper.java
@@ -0,0 +1,44 @@
+package com.example.springboot.mapper;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Select;
+import org.apache.ibatis.annotations.Update;
+import org.springframework.stereotype.Repository;
+import com.example.springboot.entity.StorageCage;
+import com.example.springboot.entity.north_glass_buffer1;
+
+@Mapper
+@Repository
+public interface AlbaniaMapper  {
+    // 鑾峰彇鍒ゆ柇璇ユ牸瀛愭槸鍚﹂渶瑕佹妸澶栫墖鎺ㄥ叆鍐呯墖浣嶇疆
+    @Select("select state from storage_cage where  cage=#{cage} and cell=#{cell} and tier=1;")
+    int selectcell(int cage, int cell);
+     // 鍒ゆ柇璇ョ瀛愭槸鍚︽湁鍚堥�傚搴︾┖鏍�
+    @Select("select cage,cell,tier,id,ROUND(id/2)as prcId,width from storage_cage where cage=#{cage1} and cell=#{cell} and state=0 and disabled=0 and width>=#{width} ORDER BY cell asc,tier asc LIMIT 1")
+    StorageCage selectCage1(int cage1, int cell, double width);
+
+    // 鍒ゆ柇绗煎瓙鍐呯幓鐠冩暟
+    @Select("select COUNT(tier)as tier from storage_cage where  cage=#{cage} and cell=#{cell} and state!=0 and state!=3;")
+    int selectsum(int cage, int cell);
+
+    // 瀹屾垚鍑虹墖涓殑鐜荤拑鐘舵��
+    @Update("update storage_cage set state=#{state} where glass_id=#{glassid} and state=3;")
+    void UpdateCageOver(String glassid, int state);
+    // 瀹屾垚杩涚墖涓殑鐜荤拑鐘舵��
+    @Update("update storage_cage set state=#{state} where glass_id=#{glassid} and state=2;")
+    void UpdateCageadd(String glassid, int state);
+    //鏌ヨ鏄惁鏈夎绫诲瀷鐨勪换鍔¤繕鏈畬鎴�
+     // 鍒ゆ柇鍑虹墖涓�1鏃讹紝鏄惁鍙洿鎺ュ嚭鐗�
+    @Select("select COUNT(state) from storage_cage where state=#{state}")
+    int SelectCageState(int state);
+    // 鑾峰彇鐜荤拑淇℃伅
+    @Select("select *,ordernumber ,glasslength_mm as glasslengthmm,glassheight_mm as glassheightmm,barcode,listnumber,boxnumber,glasslength,glassheight,FrameBarcode from north_glass_buffer1 where barcode=#{glassid}")
+    north_glass_buffer1 selectGlass(String glassid);
+    //鍒ゆ柇绗煎唴鏄惁鏈夊悎閫傜殑绫诲瀷绌烘牸
+    @Select("select id from storage_cage where glasstype=#{glasstype} and width>=#{width}+#{widths} and state=0 order by id limit 1")
+    int SelectCage(int glasstype,int width,int widths);
+    //鍒ゆ柇绗煎唴娌℃湁鐜荤拑鐨勭┖鏍�
+    @Select("select id from storage_cage where state=0 and number=0 order by id limit 1")
+    int SelectNewCell();
+    
+
+}
diff --git a/springboot-vue3/src/main/resources/JsonFile/Albania.json b/springboot-vue3/src/main/resources/JsonFile/Albania.json
new file mode 100644
index 0000000..751f96c
--- /dev/null
+++ b/springboot-vue3/src/main/resources/JsonFile/Albania.json
@@ -0,0 +1,51 @@
+{
+   "plcAddressBegin":"DB17.0",
+   "plcAddressLenght":"272",
+   "dataType":"word",
+   "parameteInfor":[
+      {
+         "codeId": "PLCToMesIn",  
+         "addressIndex":"0",
+         "addressLenght":"2", 
+         "ratio":"1", 
+         "unit":"m/min"    
+      },
+      {
+          "codeId": "PLCINID",
+          "addressIndex":"16",
+          "addressLenght":"2",
+          "ratio":"1",
+          "unit":"m/min"      
+       },
+       {
+          "codeId": "InIdState",
+          "addressIndex":"18",
+          "addressLenght":"2",
+          "ratio":"1",
+          "unit":"m/min"       
+       },
+       {
+          "codeId": "J01Quest",
+          "addressIndex":"20",
+          "addressLenght":"2",
+          "ratio":"1",
+          "unit":"mm/S"
+       },
+       {
+          "codeId": "J01id",
+          "addressIndex":"22",
+          "addressLenght":"14",
+          "ratio":"1",
+          "unit":"mm/S"
+       },
+       {
+          "codeId": "J01TurnGo",
+          "addressIndex":"38",
+          "addressLenght":"2",
+          "ratio":"1",
+          "unit":"mm/S"
+       }
+
+
+   ]
+}

--
Gitblit v1.8.0