From 326142c3254fcd2256c86e7db9e491666b868f6f Mon Sep 17 00:00:00 2001
From: 18516761980 <4761516tqsxp>
Date: 星期六, 12 九月 2020 09:28:28 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/asrs/controller/ConsoleController.java | 2
src/main/webapp/views/crn.html | 1
src/main/webapp/views/console.html | 23 ++++++-----
src/main/webapp/static/css/console.css | 9 ++--
src/main/java/com/zy/asrs/controller/CrnController.java | 2
src/main/java/com/zy/core/thread/CrnThread.java | 2
src/main/resources/application.yml | 34 ++++++-----------
src/main/java/com/zy/core/ServerBootstrap.java | 3 +
8 files changed, 34 insertions(+), 42 deletions(-)
diff --git a/src/main/java/com/zy/asrs/controller/ConsoleController.java b/src/main/java/com/zy/asrs/controller/ConsoleController.java
index 5e79f59..4554412 100644
--- a/src/main/java/com/zy/asrs/controller/ConsoleController.java
+++ b/src/main/java/com/zy/asrs/controller/ConsoleController.java
@@ -128,7 +128,7 @@
/**
* 鍫嗗灈鏈虹姸鎬佸垽鏂�
*/
- if (crnProtocol.getAlarm() > 0) {
+ if (crnProtocol.getAlarm1() > 0) {
vo.setCrnStatus(CrnStatusType.MACHINE_ERROR);
} else {
if (crnProtocol.getTaskNo()>0) {
diff --git a/src/main/java/com/zy/asrs/controller/CrnController.java b/src/main/java/com/zy/asrs/controller/CrnController.java
index e33bdf5..b2266ca 100644
--- a/src/main/java/com/zy/asrs/controller/CrnController.java
+++ b/src/main/java/com/zy/asrs/controller/CrnController.java
@@ -122,7 +122,7 @@
vo.setXLocation(crnProtocol.getWalkPos() == 1?"鏄�":"鍚�"); // 璧拌瀹氫綅
vo.setYLocation(crnProtocol.getLiftPosType().equals(CrnLiftPosType.NONE)?"鍚�":"鏄�"); // 鍗囬檷瀹氫綅
vo.setStop(crnProtocol.getCrnError1().controlStop||crnProtocol.getCrnError1().mainStop||crnProtocol.getCrnError1().remoteStop?"鏄�":"鍚�"); // 鎬ュ仠
- vo.setWarnCode(String.valueOf(crnProtocol.getAlarm())); // 寮傚父鐮�
+ vo.setWarnCode(String.valueOf(crnProtocol.getAlarm1())); // 寮傚父鐮�
}
return R.ok().add(list);
}
diff --git a/src/main/java/com/zy/core/ServerBootstrap.java b/src/main/java/com/zy/core/ServerBootstrap.java
index a7e65f4..ac5207a 100644
--- a/src/main/java/com/zy/core/ServerBootstrap.java
+++ b/src/main/java/com/zy/core/ServerBootstrap.java
@@ -33,8 +33,9 @@
@PostConstruct
@Async
- public void init(){
+ public void init() throws InterruptedException {
log.info("鏍稿績鎺у埗灞傚紑濮嬪垵濮嬪寲...............................................");
+ Thread.sleep(2000);
// 鍒濆鍖栨秷鎭槦鍒�
initMq();
// 鍒濆鍖栦笅浣嶆満绾跨▼
diff --git a/src/main/java/com/zy/core/thread/CrnThread.java b/src/main/java/com/zy/core/thread/CrnThread.java
index 48943b1..e548e0f 100644
--- a/src/main/java/com/zy/core/thread/CrnThread.java
+++ b/src/main/java/com/zy/core/thread/CrnThread.java
@@ -114,7 +114,7 @@
* 璇诲彇鐘舵��
*/
private void readStatus(){
- OperateResultExOne<byte[]> result = siemensNet.Read("DB8.18", (short) 56);
+ OperateResultExOne<byte[]> result = siemensNet.Read("DB8.18", (short) 62);
if (result.IsSuccess) {
if (null == crnProtocol) {
crnProtocol = new CrnProtocol();
diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml
index 599fc2e..423a9a0 100644
--- a/src/main/resources/application.yml
+++ b/src/main/resources/application.yml
@@ -42,8 +42,8 @@
# 鍫嗗灈鏈�1
crn[0]:
id: 1
- ip: 192.168.10.39
- port: 5015
+ ip: 192.168.6.9
+ port: 102
rack: 0
slot: 0
# 鍋忕Щ閲忥紝褰撳爢鍨涙満绔欑偣鍒楀彿=1鏃讹紝鍋忕Щ閲�=2
@@ -51,47 +51,37 @@
# 鍫嗗灈鏈哄叆搴撶珯鐐�
crnInStn[0]:
devpPlcId: ${wcs-slave.devp[0].id}
- staNo: 4
+ staNo: 5
row: 2
- bay: 1
+ bay: 0
lev: 1
# 鍫嗗灈鏈哄嚭搴撶珯鐐�
crnOutStn[0]:
devpPlcId: ${wcs-slave.devp[0].id}
- staNo: 2
+ staNo: 6
row: 1
- bay: 1
+ bay: 0
lev: 1
# 杈撻�佺嚎
devp[0]:
id: 1
- ip: 192.168.10.65
- port: 6000
+ ip: 192.168.6.120
+ port: 102
rack: 0
slot: 1
# 鍏ュ簱鍙�1
inSta[0]:
- staNo: 3
- barcode: ${wcs-slave.barcode[0].id}
- # 鍏ュ簱鍙�2
- inSta[1]:
- staNo: 7
+ staNo: 1
barcode: ${wcs-slave.barcode[0].id}
# 绌烘澘鍏ュ簱鍙�1
emptyInSta[0]:
- staNo: 3
- # 绌烘澘鍏ュ簱鍙�2
- emptyInSta[1]:
- staNo: 7
+ staNo: 1
# 鍑哄簱鍙�1
outSta[0]:
- staNo: 1
- # 鍑哄簱鍙�2
- outSta[1]:
- staNo: 5
+ staNo: 2
# 鎷f枡鍏ュ簱鍙�
pickSta[0]:
- staNo: 2
+ staNo: 3
# 鏉$爜鎵弿浠�
barcode[0]:
id: 1
diff --git a/src/main/webapp/static/css/console.css b/src/main/webapp/static/css/console.css
index 736138d..6b5faa5 100644
--- a/src/main/webapp/static/css/console.css
+++ b/src/main/webapp/static/css/console.css
@@ -183,8 +183,9 @@
top: 122px;
left: 100px;
width: 100px;
- height: 40px;
- line-height: 40px
+ height: 20px;
+ line-height: 20px;
+ position: absolute;
}
/* ------------------ 璐ф灦鎬绘垚 ------------------ */
@@ -343,7 +344,7 @@
/* 鍏ュ簱鍙� */
.cargo-put {
transform: rotateY(180deg);
- top: 285px;
+ top: 265px;
left: 313px;
position: absolute;
width: 50px;
@@ -371,7 +372,7 @@
}
/* 鎵爜鍣�1 */
#code-decoder-1 {
- top: 320px;
+ top: 300px;
left: 200px;
}
/* 鎵爜鍣ㄦ暟鎹�1 */
diff --git a/src/main/webapp/views/console.html b/src/main/webapp/views/console.html
index cd971a3..4c9672a 100644
--- a/src/main/webapp/views/console.html
+++ b/src/main/webapp/views/console.html
@@ -95,11 +95,11 @@
<!-- 绗竴鍒楋紙瀹藉害 100px锛� -->
<div class="site-row site-row-1">
- <div id="site-7" class="site" style="height: 40px;line-height: 40px">7</div>
- <div id="site-4" class="site" style="height: 40px;line-height: 40px">4</div>
- <div id="site-3" class="site" style="height: 40px;line-height: 40px;">3</div>
- <div id="site-2" class="site" style="height: 40px;line-height: 40px">2</div>
- <div id="site-1" class="site" style="height: 40px;line-height: 40px">1</div>
+ <div id="site-7" class="site" style="height: 20px;line-height: 20px;margin-bottom: 20px">7</div>
+ <div id="site-4" class="site" style="height: 20px;line-height: 20px;margin-bottom: 20px">4</div>
+ <div id="site-3" class="site" style="height: 20px;line-height: 20px;margin-bottom: 40px">3</div>
+ <div id="site-2" class="site" style="height: 20px;line-height: 20px;margin-bottom: 0px">2</div>
+ <div id="site-1" class="site" style="height: 20px;line-height: 20px;margin-bottom: 20px">1</div>
</div>
<!-- 璐ф灦 + 鍫嗗灈鏈� + 鍏ュ簱绔欑偣 + 鍑哄簱绔欑偣 -->
@@ -459,7 +459,8 @@
} else if (res.code === 403){
parent.location.href = baseUrl+"/login";
} else {
- alert(res.msg);
+ console.log(res.msg);
+
}
}
});
@@ -486,7 +487,7 @@
} else if (res.code === 403){
parent.location.href = baseUrl+"/login";
} else {
- alert(res.msg);
+ console.log(res.msg);
}
}
});
@@ -513,7 +514,7 @@
} else if (res.code === 403){
parent.location.href = baseUrl+"/login";
} else {
- alert(res.msg);
+ console.log(res.msg);
}
}
});
@@ -537,7 +538,7 @@
} else if (res.code === 403){
parent.location.href = baseUrl+"/login";
} else {
- alert(res.msg);
+ console.log(res.msg);
}
}
});
@@ -558,7 +559,7 @@
} else if (res.code === 403){
parent.location.href = baseUrl+"/login";
} else {
- alert(res.msg);
+ console.log(res.msg);
}
}
});
@@ -657,7 +658,7 @@
targetTop += 160;
break;
case 2:
- targetTop += 120;
+ targetTop += 140;
break;
case 3:
targetTop += 80;
diff --git a/src/main/webapp/views/crn.html b/src/main/webapp/views/crn.html
index e2d5ed8..1a7e120 100644
--- a/src/main/webapp/views/crn.html
+++ b/src/main/webapp/views/crn.html
@@ -96,7 +96,6 @@
<span class="select-title">鍫嗗灈鏈哄彿</span>
<div class="select-container">
<label><input type="radio" name="crnSelect" value="1" checked> 1鍙峰爢鍨涙満</label>
- <label><input type="radio" name="crnSelect" value="2"> 2鍙峰爢鍨涙満</label>
</div>
</div>
<!-- 婧愮珯/婧愬簱浣� 閫夋嫨 -->
--
Gitblit v1.9.1