xuhy
4 天以前 508f3e225df87e0da974424981e7782fc5ce875c
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TFoundationPersonServiceImpl.java
@@ -70,6 +70,8 @@
        if(b){
            throw new ServiceException("设置存在重复用餐人数");
        }
        this.remove(Wrappers.lambdaQuery(TFoundationPerson.class)
                .eq(TFoundationPerson::getMealType,dto.getMealType()));
        for (TFoundationPersonDTO tFoundationPersonDTO : foundationPersonDTOS) {
            List<TFoundationConfig> foundationConfigs = tFoundationPersonDTO.getFoundationConfigs();
            long count = foundationConfigs.stream().map(TFoundationConfig::getTypeId).distinct().count();
@@ -77,7 +79,7 @@
                throw new ServiceException("菜品重复设置");
            }
            // 添加人数
            this.updateById(tFoundationPersonDTO);
            this.saveOrUpdate(tFoundationPersonDTO);
            // 删除菜品
            foundationConfigService.remove(Wrappers.lambdaQuery(TFoundationConfig.class)
                    .eq(TFoundationConfig::getPersonId,tFoundationPersonDTO.getId()));
@@ -154,4 +156,9 @@
        }
        return list;
    }
    @Override
    public List<TFoundationPersonVO> getPersonList() {
        return this.baseMapper.getSetList();
    }
}