分拣机械手工单修改

This commit is contained in:
loujf
2022-09-25 16:10:55 +08:00
parent 2d99336ecd
commit 6ae0650e0e
5 changed files with 45 additions and 7 deletions

View File

@@ -867,7 +867,7 @@ public class LnshPackagePalletManipulatorDeviceDriver extends AbstractOpcDeviceD
if (result.getStatus() == 200 && StrUtil.equals(jsonObject.getString("status"),"200")) {
ProduceshiftorderDto dto = produceshiftorderService.findByCode(order_No);
if (this.mode == 4) {
dto.setOrder_status("0");
dto.setOrder_status("1");
} else if (this.mode == 9) {
dto.setOrder_status("2");
}

View File

@@ -857,7 +857,7 @@ public class LnshSplitManipulatorDeviceDriver extends AbstractOpcDeviceDriver im
if (result.getStatus() == 200 && StrUtil.equals(jsonObject.getString("status"),"200")) {
ProduceshiftorderDto dto = produceshiftorderService.findByCode(order_No);
if (this.mode == 4) {
dto.setOrder_status("0");
dto.setOrder_status("1");
} else if (this.mode == 9) {
dto.setOrder_status("2");
}

View File

@@ -236,7 +236,7 @@ public class LnshStationDeviceDriver extends AbstractOpcDeviceDriver implements
case 4:
//叫料
if (!requireSucess && this.move == 0) {
applyIn();
applyMaterialOut();
}
break;
case 5:
@@ -540,6 +540,36 @@ public class LnshStationDeviceDriver extends AbstractOpcDeviceDriver implements
}
}
/**
* 申请物料出库
*
* @param
*/
public synchronized boolean applyMaterialOut() {
Date date = new Date();
if (date.getTime() - this.instruction_require_time.getTime() < (long) this.instruction_require_time_out) {
log.trace("触发时间因为小于{}毫秒,而被无视", this.instruction_require_time_out);
return false;
} else {
this.instruction_require_time = date;
JSONObject json = new JSONObject();
json.put("device_code",device_code);
json.put("type","2");
json.put("is_full","1");
HttpResponse result = acsToWmsService.lnshApplyTaskToWms(json);
if (ObjectUtil.isNotEmpty(result)) {
JSONObject jsonObject = JSONObject.parseObject(result.body());
if (result.getStatus() == 200 && StrUtil.equals(jsonObject.getString("status"),"200")) {
this.writing(this.mode);
this.setRequireSucess(true);
}
}
return true;
}
}
/**
* 申请入库
*