jiangping
2024-12-05 16217be9c85f95cb236e639da6e546bb38cdc53d
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/YwPatrolLineServiceImpl.java
@@ -106,6 +106,7 @@
    }
    @Override
    @Transactional(rollbackFor = {Exception.class,BusinessException.class})
    public void updateById(YwPatrolLine ywPatrolLine) {
        if(Objects.isNull(ywPatrolLine)
                || StringUtils.isBlank(ywPatrolLine.getName())
@@ -123,7 +124,7 @@
        //循环处理 子集数据
        List<YwLinePoint> ywLinePointList = ywPatrolLine.getLinePointList();
        //是否存在相同数据
        Set<Integer> setIds = new HashSet<Integer>(ywLinePointList.stream().map(i->i.getLineId()).collect(Collectors.toList()));
        Set<Integer> setIds = new HashSet<Integer>(ywLinePointList.stream().map(i->i.getPointId()).collect(Collectors.toList()));
        if(setIds.size()!=ywLinePointList.size()){
            throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"存在相同巡检点!");
        }