small validation fix
This commit is contained in:
parent
409b96f518
commit
d4739ed1d0
|
@ -71,7 +71,7 @@ public class DefinitionPersist {
|
||||||
.iff(() -> !this.isNull(item.getSections()))
|
.iff(() -> !this.isNull(item.getSections()))
|
||||||
.on(DefinitionPersist._sections)
|
.on(DefinitionPersist._sections)
|
||||||
.over(item.getSections())
|
.over(item.getSections())
|
||||||
.using(() -> this.validatorFactory.validator(SectionPersist.SectionPersistValidator.class)),
|
.using((itm) -> this.validatorFactory.validator(SectionPersist.SectionPersistValidator.class)),
|
||||||
this.spec()
|
this.spec()
|
||||||
.must(() -> !this.isNull(item.getPages()))
|
.must(() -> !this.isNull(item.getPages()))
|
||||||
.failOn(DefinitionPersist._pages).failWith(messageSource.getMessage("Validation_Required", new Object[]{DefinitionPersist._pages}, LocaleContextHolder.getLocale())),
|
.failOn(DefinitionPersist._pages).failWith(messageSource.getMessage("Validation_Required", new Object[]{DefinitionPersist._pages}, LocaleContextHolder.getLocale())),
|
||||||
|
@ -79,7 +79,7 @@ public class DefinitionPersist {
|
||||||
.iff(() -> !this.isNull(item.getPages()))
|
.iff(() -> !this.isNull(item.getPages()))
|
||||||
.on(DefinitionPersist._pages)
|
.on(DefinitionPersist._pages)
|
||||||
.over(item.getPages())
|
.over(item.getPages())
|
||||||
.using(() -> this.validatorFactory.validator(PagePersist.PagePersistValidator.class))
|
.using((itm) -> this.validatorFactory.validator(PagePersist.PagePersistValidator.class))
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue