Commit 421b84a89014ee5f7ed5171e466426374c6e25d2
1 parent
cfd18236
更新任务下发代码
Showing
1 changed file
with
3 additions
and
3 deletions
huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/wcs/service/WcsServiceImpl.java
... | ... | @@ -335,13 +335,13 @@ public class WcsServiceImpl implements WcsService { |
335 | 335 | } |
336 | 336 | Result<TaskHeader> result = taskHeaderService.createTransferTask(insideLocation.getCode(), destinationLocation.getCode(), warehouseCode); |
337 | 337 | if (!result.isSuccess()) { |
338 | - return Result.error("创建移库任务失败"); | |
338 | + throw new JeecgBootException("创建移库任务失败"); | |
339 | 339 | } |
340 | 340 | preTaskNo = result.getResult().getId(); |
341 | 341 | taskHeader.setPreTaskNo(preTaskNo); |
342 | 342 | boolean success = taskHeaderService.updateById(taskHeader); |
343 | 343 | if (!success) { |
344 | - return Result.error("更新任务状态失败"); | |
344 | + throw new JeecgBootException("更新任务状态失败"); | |
345 | 345 | } |
346 | 346 | return Result.error("先执行移库任务"); |
347 | 347 | } |
... | ... | @@ -360,7 +360,7 @@ public class WcsServiceImpl implements WcsService { |
360 | 360 | taskHeader.setPreTaskNo(preTaskNo); |
361 | 361 | boolean success = taskHeaderService.updateById(taskHeader); |
362 | 362 | if (!success) { |
363 | - return Result.error("更新任务状态失败"); | |
363 | + throw new JeecgBootException("更新任务状态失败"); | |
364 | 364 | } |
365 | 365 | } |
366 | 366 | } |
... | ... |