501流程测试修改,作废流程添加
This commit is contained in:
@@ -124,7 +124,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.error(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -146,7 +146,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.error(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -162,7 +162,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -177,7 +177,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -211,7 +211,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -227,7 +227,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -296,12 +296,17 @@ public class PdaServiceImp implements PdaService {
|
||||
//修改拣选数量
|
||||
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());
|
||||
mydoJobDetailService.updateMydoJobDetail(mydoJobDetail);
|
||||
updateTagTaskStatus(mydoJobDetail,basWarehouse);
|
||||
|
||||
//修改单据实际数量
|
||||
String inOrOutDId = mydoJobDetail.getInOrOutDId();
|
||||
OutStockoutDetail outStockoutDetail = outStockoutDetailService.selectOutStockoutDetailByStockoutDetailId(inOrOutDId);
|
||||
outStockoutDetail.setAssignNum(outStockoutDetail.getAssignNum().add(Convert.toBigDecimal(mydoJobDetail.getPickQuantity())));
|
||||
outStockoutDetailService.updateOutStockoutDetail(outStockoutDetail);
|
||||
//修改电子标签
|
||||
updateTagTaskStatus(mydoJobDetail, basWarehouse);
|
||||
}
|
||||
//判断拣选数量是否等于出库数量
|
||||
MydoJobDetail mydoJobDetailParam = new MydoJobDetail();
|
||||
@@ -316,10 +321,10 @@ public class PdaServiceImp implements PdaService {
|
||||
String result = map.get("v_result").toString();
|
||||
if ("10".equals(result)) {
|
||||
//通知wcs 出库确认
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse);
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse,mydoJob);
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
} else {
|
||||
return AjaxResult.success();
|
||||
@@ -394,10 +399,10 @@ public class PdaServiceImp implements PdaService {
|
||||
pdaMapper.outMakeSure(map);
|
||||
String result = map.get("v_result").toString();
|
||||
if ("10".equals(result)) {
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse);
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse,mydoJob);
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
} else {
|
||||
return AjaxResult.success();
|
||||
@@ -443,10 +448,9 @@ public class PdaServiceImp implements PdaService {
|
||||
pdaMapper.checkMakeSure(map);
|
||||
String result = map.get("v_result").toString();
|
||||
if ("10".equals(result)) {
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse);
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
return AjaxResult.success();
|
||||
@@ -477,8 +481,8 @@ public class PdaServiceImp implements PdaService {
|
||||
* @param trayCodeMakeSure
|
||||
* @param basWarehouse
|
||||
*/
|
||||
private void deleteTagTask(TrayCodeMakeSure trayCodeMakeSure, BasWarehouse basWarehouse) {
|
||||
if ("2".equals(basWarehouse.getWarehouseType())) {
|
||||
private void deleteTagTask(TrayCodeMakeSure trayCodeMakeSure, BasWarehouse basWarehouse,MydoJob mydoJob) {
|
||||
if ("2".equals(basWarehouse.getWarehouseType())&&"23".equals(mydoJob.getInOrOut())) {
|
||||
BasTag basTag = basTagService.selectBasTagByTrayCode(trayCodeMakeSure.getTrayCode());
|
||||
basTag.setTrayCode("");
|
||||
basTagService.updateBasTag(basTag);
|
||||
@@ -491,17 +495,21 @@ public class PdaServiceImp implements PdaService {
|
||||
.map(TagTask::getId)
|
||||
.toArray(Long[]::new));
|
||||
}
|
||||
//通知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());
|
||||
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());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public AjaxResult outException(TrayCodeMakeSure trayCodeMakeSure) {
|
||||
//判断任务是否存在
|
||||
MydoJob mydoJobParam = new MydoJob();
|
||||
@@ -559,7 +567,8 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
//return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -574,7 +583,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user