同步最新本地代码
This commit is contained in:
@@ -80,7 +80,7 @@ public class GetDeviceSrgvMap {
|
||||
AgvDto dto = new AgvDto();
|
||||
dto.setId(d.getDeviceId() == null ? "" : String.format("%04d", d.getDeviceId()));
|
||||
dto.setTaskNo(d.getTaskNo() == null ? "" : String.valueOf(d.getTaskNo()));
|
||||
dto.setIsThere((d.getWorkPhase() >= 3 && d.getWorkPhase() < 6 ? "1" : "0"));
|
||||
dto.setIsThere(d.getCargoFlag()==256?"1":"0");
|
||||
Integer wp = d.getWorkPhase();
|
||||
String status = "0";
|
||||
if (wp != null) {
|
||||
@@ -90,6 +90,9 @@ public class GetDeviceSrgvMap {
|
||||
}
|
||||
dto.setStatus(status);
|
||||
dto.setLocation(d.getCurrSite() == null ? "" : d.getCurrSite());
|
||||
dto.setRow(d.getCurrSite() == null ? "" : d.getCurrSite().substring(2,4));
|
||||
dto.setColumn(d.getCurrSite() == null ? "" :d.getCurrSite().substring(0,2));
|
||||
dto.setLayer(d.getCurrSite() == null ? "" : d.getCurrSite().substring(4,6));
|
||||
dto.setAlarm(d.getAlarm() == null ? "" : String.valueOf(d.getAlarm()));
|
||||
dto.setAlarmMsg(DictUtils.getDictLabel("srgv_alarm", d.getAlarm() == null ? "" : String.valueOf(d.getAlarm())));
|
||||
if (d.getTaskNo() != null && d.getTaskNo() > 0) {
|
||||
@@ -132,6 +135,9 @@ public class GetDeviceSrgvMap {
|
||||
private String isThere;
|
||||
private String status;
|
||||
private String location;
|
||||
private String row;
|
||||
private String column;
|
||||
private String layer;
|
||||
private String alarm;
|
||||
private String alarmMsg;
|
||||
private String trayCode;
|
||||
|
||||
@@ -99,8 +99,17 @@ public class GetDeviceSsjMap {
|
||||
dto.setRotationDirection(calcRotationDirection(d.getTaskNo()));
|
||||
dto.setAlarm(String.valueOf(d.getException()));
|
||||
dto.setAlarmMsg(DictUtils.getDictLabel("ssj_ex", String.valueOf(d.getException())));
|
||||
dto.setDW(String.valueOf(d.getDw()));
|
||||
dto.setKX(String.valueOf(d.getKx()));
|
||||
if (!dto.getTaskNo().equals("0")){
|
||||
if (dto.getKX().equals("0")){
|
||||
dto.setDW("1");
|
||||
}else {
|
||||
dto.setDW("0");
|
||||
}
|
||||
}else {
|
||||
dto.setDW("0");
|
||||
}
|
||||
|
||||
if (d.getTaskNo() > 0) {
|
||||
try {
|
||||
MydoJob job = mydoJobService.selectMydoJobByTaskNo(Long.valueOf(d.getTaskNo()));
|
||||
@@ -128,16 +137,10 @@ public class GetDeviceSsjMap {
|
||||
*/
|
||||
private String calcRotationDirection(int taskNo) {
|
||||
try {
|
||||
if (taskNo <= 0) return "0";
|
||||
MydoJob job = mydoJobService.selectMydoJobByTaskNo((long) taskNo);
|
||||
if (job == null || job.getInOrOut() == null) return "0";
|
||||
int val;
|
||||
try {
|
||||
val = Integer.parseInt(job.getInOrOut());
|
||||
} catch (NumberFormatException e) {
|
||||
if (taskNo <= 0) {
|
||||
return "0";
|
||||
}
|
||||
return val >= 20 ? "2" : "1";
|
||||
return taskNo <= 50000 ? "1" : "2";
|
||||
} catch (Exception e) {
|
||||
return "0";
|
||||
}
|
||||
|
||||
@@ -80,7 +80,7 @@ public class GetDeviceTsjMap {
|
||||
String code = entry.getKey();
|
||||
DeviceTsj d = entry.getValue();
|
||||
TsjDto dto = new TsjDto();
|
||||
dto.setId(String.valueOf(d.getId()));
|
||||
dto.setId("TW001");
|
||||
dto.setLayer(d.getDqcs() == null ? "" : String.valueOf(d.getDqcs()));
|
||||
dto.setTaskNo(d.getRwh() == null ? "" : String.valueOf(d.getRwh()));
|
||||
dto.setZxjd(d.getJdbz() == null ? "" : String.valueOf(d.getJdbz()));
|
||||
|
||||
@@ -96,6 +96,7 @@ public class Wcs2wmsgetEmptyCargoSpace {
|
||||
dto.setTrayCode(getText(node, "trayCode"));
|
||||
dto.setProductCode(getText(node, "productCode"));
|
||||
dto.setProductName(getText(node, "productName"));
|
||||
dto.setCargoSpaceId(getText(node, "cargoSpaceId"));
|
||||
return dto;
|
||||
}
|
||||
|
||||
@@ -125,5 +126,6 @@ public class Wcs2wmsgetEmptyCargoSpace {
|
||||
private String trayCode;
|
||||
private String productCode;
|
||||
private String productName;
|
||||
private String cargoSpaceId;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user