勋章等级配置限制
This commit is contained in:
@@ -54,6 +54,10 @@ public class MedalSeriesAdminService {
|
||||
if (!medal.getEnable().equals(Boolean.TRUE)) {
|
||||
throw new AdminServiceException(String.format("勋章ID:%s状态为无效", medalSeriesRef.getMedalId()));
|
||||
}
|
||||
List<MedalSeriesRef> seriesRefs = medalSeriesRefService.listByMedalIds(Arrays.asList(medalSeriesRef.getMedalId()));
|
||||
if (CollectionUtils.isNotEmpty(seriesRefs)) {
|
||||
throw new AdminServiceException(String.format("勋章ID:%s已经配置等级,配置id为:%s", medalSeriesRef.getMedalId(), seriesRefs.get(0).getSeriesId()));
|
||||
}
|
||||
}
|
||||
MedalSeries medalSeries = new MedalSeries();
|
||||
BeanUtils.copyProperties(medalSeriesAdminVo, medalSeries);
|
||||
|
Reference in New Issue
Block a user