Merge remote-tracking branch 'origin/master_merge' into master_merge

This commit is contained in:
zhouz
2024-07-13 23:48:52 +08:00

View File

@@ -153,15 +153,16 @@ public class BstIvtPackageinfoivtServiceImpl extends ServiceImpl<BstIvtPackagein
throw new BadRequestException("该任务未执行或不存在!");
}
//已分配过二次分配点位
// if (StringUtils.isNotBlank(baseTask.getResponse_param())) {
// if (baseTask.getResponse_param().equals(IOSEnum.IS_SEND.code("是"))) {
// if (PackageInfoIvtEnum.TASK_ACTION_TYPE.code("取货分配").equals(actionType)) {
// return baseTask.getPoint_code1();
// } else if (PackageInfoIvtEnum.TASK_ACTION_TYPE.code("放货分配").equals(actionType)) {
// return baseTask.getPoint_code2();
// }
// }
// }
if (StringUtils.isNotBlank(baseTask.getResponse_param())) {
if (baseTask.getResponse_param().equals(IOSEnum.IS_SEND.code(""))) {
if (PackageInfoIvtEnum.TASK_ACTION_TYPE.code("取货分配").equals(actionType)) {
return baseTask.getPoint_code1();
}
// else if (PackageInfoIvtEnum.TASK_ACTION_TYPE.code("放货分配").equals(actionType)) {
//return baseTask.getPoint_code2();
// }
}
}
BstIvtPackageinfoivt newPoint;
String taskPointType = null;
//空载具缓存位特殊二次分配逻辑:先判断是否有执行中的行架任务或补空载具任务,如未完成,不分配点位
@@ -192,11 +193,11 @@ public class BstIvtPackageinfoivtServiceImpl extends ServiceImpl<BstIvtPackagein
//标记二次分配已分配过点位
baseTask.setResponse_param(IOSEnum.IS_NOTANDYES.code(""));
taskService.updateById(baseTask);
log.info("一楼装箱区二次分配任务编号为:" + taskCode + ",接口返回最新点位:---------------------------------------------" + newPoint.getPoint_code());
log.info("一楼装箱区二次分配" + taskCode + ",接口返回最新点位:---------------------------------------------" + newPoint.getPoint_code());
return newPoint.getPoint_code();
} else {
log.info("一楼装箱区二次分配任务编号为:" + taskCode + ",分配失败,暂无点位资源或点位外层有载具阻挡!");
throw new BadRequestException("一楼装箱区二次分配任务编号为:" + taskCode + ",分配失败,暂无点位资源或点位外层有载具阻挡!");
log.info("一楼装箱区二次分配" + taskCode + ",分配失败,暂无点位资源或点位外层有载具阻挡!");
throw new BadRequestException("一楼装箱区二次分配" + taskCode + ",分配失败,暂无点位资源或点位外层有载具阻挡!");
}
}
@@ -516,8 +517,9 @@ public class BstIvtPackageinfoivtServiceImpl extends ServiceImpl<BstIvtPackagein
private void upDateIvtOrTask(SchBaseTask baseTask, String pointCode, boolean isUpDateTask) {
UpdateWrapper<BstIvtPackageinfoivt> updateWrapper = new UpdateWrapper<>();
updateWrapper.eq("point_code", pointCode);
updateWrapper.setSql("ivt_status = '0', container_name = null");
//清空起点库存状态
updateWrapper.set("ivt_status", "0");
updateWrapper.set("container_name", null);
// 清空起点库存状态
bstIvtPackageinfoivtMapper.update(null, updateWrapper);
if (isUpDateTask) {
//标记桁架任务取空载具完成