zhou zhou
17 小时以前 2f8e173048d22c5b40612c3538b9c1aa5a5397f6
rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/InBoundServiceImpl.java
@@ -275,8 +275,17 @@
            if (!basStationService.updateById(station)) {
                throw new CoolException("站点状态更新失败!!");
            }
            if (!locService.update(new LambdaUpdateWrapper<Loc>().eq(Loc::getCode, task.getTargLoc())
                    .set(Loc::getUseStatus, LocStsType.LOC_STS_TYPE_S.type).set(Loc::getBarcode, param.getContainerNo()))) {
            Loc taskLoc = locService.getOne(new LambdaQueryWrapper<Loc>()
                    .eq(Loc::getCode, task.getTargLoc())
                    .last("limit 1"), false);
            if (Objects.isNull(taskLoc)) {
                throw new CoolException("库位预约失败!!");
            }
            taskLoc.setUseStatus(LocStsType.LOC_STS_TYPE_S.type)
                    .setBarcode(param.getContainerNo())
                    .setUpdateBy(loginUserId)
                    .setUpdateTime(new Date());
            if (!locService.updateById(taskLoc)) {
                throw new CoolException("库位预约失败!!");
            }
            return R.ok("任务生成完毕!");