出入库限制优化
This commit is contained in:
@@ -545,9 +545,9 @@ public class ApiServiceImpl implements IApiService {
|
||||
// 3.是否已经有正在执行的入库任务
|
||||
job = new MydoJob().builder().inOrOut(STOCKIN).build();
|
||||
tasks = mydoJobService.selectMydoJobList(job);
|
||||
if (tasks.size() != 0) {
|
||||
log.info("【警告】wms下发出库任务失败,已经存在正在执行的入库任务,请稍后重试");
|
||||
return AjaxResult.error("【警告】wms下发出库任务失败,已经存在正在执行的入库任务,请稍后重试");
|
||||
if (tasks.size() > 0) {
|
||||
log.info("【警告】wms下发出库任务失败,已经有正在执行的入库任务,请稍后重试");
|
||||
return AjaxResult.error("【警告】wms下发出库任务失败,已经有正在执行的入库任务,请稍后重试");
|
||||
}
|
||||
|
||||
//生成出库作业
|
||||
|
||||
@@ -293,6 +293,7 @@ public class DdjThread implements Runnable {
|
||||
|
||||
//正常下发
|
||||
if (ddj.getYxxf() == 1 && ddj.getSbzt() == 0 ) {
|
||||
|
||||
//检查是否有正在执行的堆垛机队列
|
||||
Long rwh = ddj.getRwh();
|
||||
DdjDeviceExecutionQueue ddjDeviceExecutionQueueRunningParam = new DdjDeviceExecutionQueue();
|
||||
@@ -320,9 +321,9 @@ public class DdjThread implements Runnable {
|
||||
ddjDeviceExecutionQueue.setXfsj(DateUtil.formatDateTime(DateUtil.date()));
|
||||
ddjDeviceExecutionQueue.setDdjxf("1");
|
||||
ddjDeviceExecutionQueueService.updateDdjDeviceExecutionQueue(ddjDeviceExecutionQueue);
|
||||
log.info("【堆垛机入库】下发任务成功,任务执行中, 任务号:{}", ddjDeviceExecutionQueue.getRwh());
|
||||
log.info("【堆垛机执行】下发任务成功,任务执行中, 任务号:{}", ddjDeviceExecutionQueue.getRwh());
|
||||
} else {
|
||||
log.error("【堆垛机入库】执行异常, 堆垛机下发任务失败!");
|
||||
log.error("【堆垛机执行】执行异常, 堆垛机下发任务失败!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -124,11 +124,14 @@ public class PortConvThread implements Runnable {
|
||||
|
||||
//输送机状态
|
||||
if (!convChecked(inSsjDevice)) return;
|
||||
//更新入库任务阶段
|
||||
updateMydoJob(inSsjDevice);
|
||||
|
||||
//请求wms获取入库任务
|
||||
requestMydoJob(inSsjDevice);
|
||||
|
||||
//更新入库任务阶段
|
||||
updateMydoJob(inSsjDevice);
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -171,7 +174,7 @@ public class PortConvThread implements Runnable {
|
||||
return;
|
||||
}
|
||||
|
||||
int stockoutMydoJob = mydoJobService.selectInOrOutMydoJobList(
|
||||
int stockoutMydoJob = mydoJobService.selectMydoJobList(
|
||||
new MydoJob().builder().inOrOut(STOCKOUT).build()
|
||||
).size();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user