1
昨天 24bb6dccd9f78079c212f652d267a025c52e5361
rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/PdaOutStockServiceImpl.java
@@ -273,7 +273,7 @@
        }
        boolean allTaskItemsFinished = allTaskItems.stream().allMatch(item -> {
            BigDecimal workQty = BigDecimal.valueOf(Objects.isNull(item.getWorkQty()) ? 0D : item.getWorkQty());
            BigDecimal qty = BigDecimal.valueOf(Objects.isNull(item.getQty()) ? 0D : item.getQty());
            BigDecimal qty = BigDecimal.valueOf(Objects.isNull(item.getAnfme()) ? 0D : item.getAnfme());
            return workQty.compareTo(qty) == 0;
        });
        if (allTaskItemsFinished) {
@@ -282,6 +282,17 @@
                    .setUpdateTime(new Date());
            if (!taskService.updateById(task)) {
                throw new CoolException("任务状态更新失败");
            }
            if (task.getTaskType().equals(TaskType.TASK_TYPE_OUT.type)) {
                BasStation basStation = basStationService.getOne(new LambdaQueryWrapper<BasStation>()
                        .eq(BasStation::getBarcode, param.getContainerNo()));
                if (!Cools.isEmpty(basStation)) {
                    basStation.setUseStatus(LocStsType.LOC_STS_TYPE_D.type);
                    basStation.setUpdateTime(new Date());
                    if (!basStationService.updateById(basStation)){
                        throw new CoolException("站点状态更新失败");
                    }
                }
            }
        }
@@ -525,3 +536,4 @@
                item -> new BigDecimal(item.getAnfme().toString()).equals(new BigDecimal(item.getQty().toString())));
    }
}