回流输送机发送去向
This commit is contained in:
@@ -196,15 +196,18 @@
|
|||||||
|
|
||||||
if (warehouseId === '02') {
|
if (warehouseId === '02') {
|
||||||
this.entranceList = [
|
this.entranceList = [
|
||||||
{ id: 'G1001', name: 'G1001' },
|
{ id: 'G1003', name: 'G1003' },
|
||||||
{ id: 'G1007', name: 'G1007' }
|
{ id: 'G1009', name: 'G1009' }
|
||||||
]
|
]
|
||||||
} else if (warehouseId === '13') {
|
} else if (warehouseId === '13') {
|
||||||
this.entranceList = [
|
this.entranceList = [
|
||||||
{ id: 'G3006', name: 'G3006' },
|
{ id: 'G2012', name: 'G2012' },
|
||||||
{ id: 'G2007', name: 'G2007' },
|
{ id: 'G3009', name: 'G3009' },
|
||||||
{ id: 'G4006', name: 'G4006' },
|
{ id: 'G3018', name: 'G3018' },
|
||||||
{ id: 'G5006', name: 'G5006' }
|
{ id: 'G4009', name: 'G4009' },
|
||||||
|
{ id: 'G4018', name: 'G4018' },
|
||||||
|
{ id: 'G5009', name: 'G5009' },
|
||||||
|
{ id: 'G5018', name: 'G5018' },
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -43,9 +43,9 @@ public class ToWmsApiController {
|
|||||||
/**
|
/**
|
||||||
* 入库任务请求
|
* 入库任务请求
|
||||||
*/
|
*/
|
||||||
@PostMapping("/requestEnterByTaskNo")
|
@PostMapping("/requestEnterByEnterId")
|
||||||
public AjaxResult requestEnterByTaskNo(@RequestBody RequestEnter requestEnter) {
|
public AjaxResult requestEnterByEnterId(@RequestBody RequestEnter requestEnter) {
|
||||||
AjaxResult ajaxResult = toWmsService.requestEnterByTaskNo(requestEnter);
|
AjaxResult ajaxResult = toWmsService.requestEnterByEnterId(requestEnter);
|
||||||
RequestLog requestLog = requestLogService.getRequestLog(JSONUtil.toJsonStr(requestEnter), "入库任务请求(任务号)",ajaxResult);
|
RequestLog requestLog = requestLogService.getRequestLog(JSONUtil.toJsonStr(requestEnter), "入库任务请求(任务号)",ajaxResult);
|
||||||
requestLogService.insertRequestLog(requestLog);
|
requestLogService.insertRequestLog(requestLog);
|
||||||
return ajaxResult;
|
return ajaxResult;
|
||||||
|
|||||||
@@ -53,4 +53,11 @@ public interface IToWmsService {
|
|||||||
* 入库任务请求根据任务号
|
* 入库任务请求根据任务号
|
||||||
*/
|
*/
|
||||||
AjaxResult requestEnterByTaskNo(RequestEnter requestEnter);
|
AjaxResult requestEnterByTaskNo(RequestEnter requestEnter);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据入口获取入库任务
|
||||||
|
* @param requestEnter
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
AjaxResult requestEnterByEnterId(RequestEnter requestEnter);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -148,8 +148,6 @@ public class ToWmsServiceImpl implements IToWmsService {
|
|||||||
tagTask.setFloor("0");
|
tagTask.setFloor("0");
|
||||||
tagTaskService.insertTagTask(tagTask);
|
tagTaskService.insertTagTask(tagTask);
|
||||||
}
|
}
|
||||||
//开启线程
|
|
||||||
//new Thread(new TagOutReadThread(basTag.getIp())).start();
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case "3":
|
case "3":
|
||||||
@@ -328,4 +326,22 @@ public class ToWmsServiceImpl implements IToWmsService {
|
|||||||
}
|
}
|
||||||
return AjaxResult.success(new RequestEnterResponse(mydoJob.getCargoSpaceId(), mydoJob.getTrayCode(), mydoJob.getTaskNo()));
|
return AjaxResult.success(new RequestEnterResponse(mydoJob.getCargoSpaceId(), mydoJob.getTrayCode(), mydoJob.getTaskNo()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public AjaxResult requestEnterByEnterId(RequestEnter requestEnter) {
|
||||||
|
MydoJob mydoJobParam = new MydoJob();
|
||||||
|
mydoJobParam.setEntranceId(requestEnter.getEntranceId());
|
||||||
|
mydoJobParam.setStatus("1");
|
||||||
|
List<MydoJob> mydoJobs = mydoJobService.selectMydoJobListApi(mydoJobParam);
|
||||||
|
if (mydoJobs.isEmpty()) {
|
||||||
|
return AjaxResult.warn(MessageUtils.message("warn.message"));
|
||||||
|
}
|
||||||
|
MydoJob mydoJob = mydoJobs.get(0);
|
||||||
|
if ("1".equals(mydoJob.getExecutionPhase())) {
|
||||||
|
mydoJob.setExecutionPhase("2");
|
||||||
|
mydoJob.setStatus("2");
|
||||||
|
mydoJobService.updateMydoJob(mydoJob);
|
||||||
|
}
|
||||||
|
return AjaxResult.success(new RequestEnterResponse(mydoJob.getCargoSpaceId(), mydoJob.getTrayCode(), mydoJob.getTaskNo()));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -93,15 +93,17 @@ public class TagOutReadThread implements Runnable {
|
|||||||
//出库确认
|
//出库确认
|
||||||
TrayCodeMakeSure trayCodeMakeSure = new TrayCodeMakeSure();
|
TrayCodeMakeSure trayCodeMakeSure = new TrayCodeMakeSure();
|
||||||
trayCodeMakeSure.setTrayCode(basTag.getTrayCode());
|
trayCodeMakeSure.setTrayCode(basTag.getTrayCode());
|
||||||
|
trayCodeMakeSure.setPickId(basTag.getPickAdd());
|
||||||
AjaxResult ajaxResult = pdaService.outMakeSure(trayCodeMakeSure);
|
AjaxResult ajaxResult = pdaService.outMakeSure(trayCodeMakeSure);
|
||||||
if (ajaxResult.isSuccess()) {
|
if (ajaxResult.isSuccess()) {
|
||||||
//删除标签绑定信息
|
/*//删除标签绑定信息
|
||||||
basTag.setSendCompleted("0");
|
basTag.setSendCompleted("0");
|
||||||
basTag.setTrayCode("");
|
basTag.setTrayCode("");
|
||||||
basTagService.updateBasTag(basTag);
|
basTagService.updateBasTag(basTag);
|
||||||
//删除tagList
|
//删除tagList
|
||||||
tagTaskMapper.deleteTagTaskByIds(allTagTasks.stream().map(TagTask::getId).toArray(Long[]::new));
|
tagTaskMapper.deleteTagTaskByIds(allTagTasks.stream().map(TagTask::getId).toArray(Long[]::new));*/
|
||||||
log.info("下发电子标签灭灯:ip:{},id:{}", basTag.getIp(), basTag.getId());
|
log.info("下发电子标签灭灯:ip:{},id:{}", basTag.getIp(), basTag.getId());
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,6 +21,8 @@ public class TrayCodeMakeSure {
|
|||||||
private String warehouseId;
|
private String warehouseId;
|
||||||
|
|
||||||
private String exitId;
|
private String exitId;
|
||||||
|
|
||||||
|
private String pickId;
|
||||||
//拣选详情列表
|
//拣选详情列表
|
||||||
private List<MydoJobDetail> mydoJobDetailList;
|
private List<MydoJobDetail> mydoJobDetailList;
|
||||||
//盘点详情列表
|
//盘点详情列表
|
||||||
|
|||||||
@@ -335,6 +335,7 @@ public class PdaServiceImp implements PdaService {
|
|||||||
if ("10".equals(result)) {
|
if ("10".equals(result)) {
|
||||||
//通知wcs 出库确认
|
//通知wcs 出库确认
|
||||||
deleteTagTask(trayCodeMakeSure, basWarehouse, mydoJob);
|
deleteTagTask(trayCodeMakeSure, basWarehouse, mydoJob);
|
||||||
|
wcsMakeSure(trayCodeMakeSure, mydoJob);
|
||||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||||
@@ -358,10 +359,6 @@ public class PdaServiceImp implements PdaService {
|
|||||||
|
|
||||||
for (MydoJobDetail mydoJobDetail : mydoJobDetailList) {
|
for (MydoJobDetail mydoJobDetail : mydoJobDetailList) {
|
||||||
|
|
||||||
//修改拣选数量
|
|
||||||
//MydoJobDetail mydoJobDetailOld = mydoJobDetailService.selectMydoJobDetailByJobDetailId(mydoJobDetail.getJobDetailId());
|
|
||||||
/*BigDecimal oldPickQuantity = Convert.toBigDecimal(mydoJobDetailOld.getPickQuantity());
|
|
||||||
BigDecimal newPickQuantity = Convert.toBigDecimal(mydoJobDetail.getOutQuantity());*/
|
|
||||||
mydoJobDetail.setPickQuantity(mydoJobDetail.getOutQuantity());
|
mydoJobDetail.setPickQuantity(mydoJobDetail.getOutQuantity());
|
||||||
mydoJobDetailService.updateMydoJobDetail(mydoJobDetail);
|
mydoJobDetailService.updateMydoJobDetail(mydoJobDetail);
|
||||||
|
|
||||||
@@ -397,6 +394,7 @@ public class PdaServiceImp implements PdaService {
|
|||||||
String result = map.get("v_result").toString();
|
String result = map.get("v_result").toString();
|
||||||
if ("10".equals(result)) {
|
if ("10".equals(result)) {
|
||||||
deleteTagTask(trayCodeMakeSure, basWarehouse, mydoJob);
|
deleteTagTask(trayCodeMakeSure, basWarehouse, mydoJob);
|
||||||
|
wcsMakeSure(trayCodeMakeSure, mydoJob);
|
||||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||||
@@ -517,6 +515,7 @@ public class PdaServiceImp implements PdaService {
|
|||||||
if ("2".equals(basWarehouse.getWarehouseType()) && "23".equals(mydoJob.getInOrOut())) {
|
if ("2".equals(basWarehouse.getWarehouseType()) && "23".equals(mydoJob.getInOrOut())) {
|
||||||
BasTag basTag = basTagService.selectBasTagByTrayCode(trayCodeMakeSure.getTrayCode());
|
BasTag basTag = basTagService.selectBasTagByTrayCode(trayCodeMakeSure.getTrayCode());
|
||||||
basTag.setTrayCode("");
|
basTag.setTrayCode("");
|
||||||
|
basTag.setSendCompleted("0");
|
||||||
basTagService.updateBasTag(basTag);
|
basTagService.updateBasTag(basTag);
|
||||||
//删除电子标签
|
//删除电子标签
|
||||||
TagTask param = new TagTask();
|
TagTask param = new TagTask();
|
||||||
@@ -527,19 +526,35 @@ public class PdaServiceImp implements PdaService {
|
|||||||
.map(TagTask::getId)
|
.map(TagTask::getId)
|
||||||
.toArray(Long[]::new));
|
.toArray(Long[]::new));
|
||||||
}
|
}
|
||||||
if (mydoJob.getExitId().startsWith("fluent")) {
|
|
||||||
//通知wcs出库确认成功
|
|
||||||
HashMap<String, String> outMydojobMakeSureParam = new HashMap<>();
|
|
||||||
outMydojobMakeSureParam.put("trayCode", trayCodeMakeSure.getTrayCode());
|
|
||||||
AjaxResult ajaxResult = iToWcsService.outMydojobMakeSure(outMydojobMakeSureParam);
|
|
||||||
if (!ajaxResult.isSuccess()) {
|
|
||||||
throw new RuntimeException(ajaxResult.toString());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通知wcs出库确认成功
|
||||||
|
* @param trayCodeMakeSure
|
||||||
|
* @param mydoJob
|
||||||
|
*/
|
||||||
|
private void wcsMakeSure(TrayCodeMakeSure trayCodeMakeSure, MydoJob mydoJob) {
|
||||||
|
String type;
|
||||||
|
if (mydoJob.getExitId().startsWith("fluent")) {
|
||||||
|
//流利架
|
||||||
|
type = "1";
|
||||||
|
}else {
|
||||||
|
//输送机
|
||||||
|
type = "2";
|
||||||
|
}
|
||||||
|
//通知wcs出库确认成功
|
||||||
|
HashMap<String, String> outMydojobMakeSureParam = new HashMap<>();
|
||||||
|
outMydojobMakeSureParam.put("trayCode", trayCodeMakeSure.getTrayCode());
|
||||||
|
outMydojobMakeSureParam.put("type", type);
|
||||||
|
outMydojobMakeSureParam.put("pickSsj", trayCodeMakeSure.getPickId());
|
||||||
|
AjaxResult ajaxResult = iToWcsService.outMydojobMakeSure(outMydojobMakeSureParam);
|
||||||
|
if (!ajaxResult.isSuccess()) {
|
||||||
|
throw new RuntimeException(ajaxResult.toString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@Transactional(rollbackFor = Exception.class)
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public AjaxResult outException(TrayCodeMakeSure trayCodeMakeSure) {
|
public AjaxResult outException(TrayCodeMakeSure trayCodeMakeSure) {
|
||||||
@@ -604,6 +619,7 @@ public class PdaServiceImp implements PdaService {
|
|||||||
if ("10".equals(result)) {
|
if ("10".equals(result)) {
|
||||||
//删除电子标签信息
|
//删除电子标签信息
|
||||||
deleteTagTask(trayCodeMakeSure, basWarehouse, mydoJob);
|
deleteTagTask(trayCodeMakeSure, basWarehouse, mydoJob);
|
||||||
|
wcsMakeSure(trayCodeMakeSure, mydoJob);
|
||||||
//自动分配
|
//自动分配
|
||||||
return outStockoutService.autoAllot(stockOutId);
|
return outStockoutService.autoAllot(stockOutId);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user