PLC调度

master
erzhongxmu 2022-10-22 13:16:31 +08:00
parent 140a4a951e
commit b034d508a2
2 changed files with 17 additions and 3 deletions

View File

@ -356,7 +356,21 @@ public class MdBinController extends BaseController {
jsonParts.put("des", resultt.get(i).get("des"));
jsonParts.put("tincount", resultt.get(i).get("tincount"));
try {
if ("fanxiang".equals(type)) {
try {
int hangshuint = Integer.parseInt(hangshu);
int xnode = Integer.parseInt(resultt.get(i).get("xnode").toString());
jsonParts.put("xnode", hangshuint + 1 - xnode);
} catch (Exception e) {
}
} else {
jsonParts.put("xnode", resultt.get(i).get("xnode"));
}
jsonParts.put("xnode", resultt.get(i).get("xnode"));
jsonParts.put("ynode", resultt.get(i).get("ynode"));
@ -407,7 +421,7 @@ public class MdBinController extends BaseController {
String hxstepNum = "1";
xstepNum = Integer.toString(xStep);
ystepNum = Integer.toString(yStep);
if(y0.equals("1")){
if(y0.equals("01")){
wmsPlcController.run("","runx",xstepNum);
}else{
wmsPlcController.run("","runy",ystepNum);
@ -419,7 +433,7 @@ public class MdBinController extends BaseController {
wmsPlcController.run("","change",hxstepNum);
}
if(y0.equals("1")){
if(y0.equals("01")){
wmsPlcController.run("","runy",ystepNum);
}else{
wmsPlcController.run("","runx",xstepNum);

View File

@ -31,7 +31,7 @@
</span>
<span style="vertical-align:middle;display:-moz-inline-box;display:inline-block;width: 90px;text-align:right;">
<button onclick="chaxun('zhengxiang')">查询</button> </span>
<button onclick="chaxun('fanxiang')">调度</button> </span>
<button onclick="chaxun('diaodu')">调度</button> </span>
</div>