beyond the action-method based bypass it's possible to bypass validation with an annotation which is similar to a view-controller annotation. anyway, it works the opposite way round. if the annotation is used validation is bypassed.
you can use the annotation on the first bean (= page/backing bean), the first property (of the page/backing bean), the last base object (owner of the property) and the bound property.
that means something like:
#{pageBean.bean1.bean2.person.firstName}
the green parts are possible targets for @BypassValidationController
a simple example:
![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgsA1d_i8bY2qHGyAFZNh2ki0ILOhhy-BbelS8022k_GTI6cAZJSOX9tQ0YfuBpsVyn2OMnVB1EDGEjSab3R28K6E_sc8Q_aCnZBoj4LoQOw86XfSHDgKFHK3WoO7HGdG2KY0SeyJHNrx4/s400/BypassValidationController.png)
1) bypassed extval-validation for every property bound via: #{personPage2. ...}
attention: only skipable validations are bypassed by default. so e.g. jpa based validation continues to work. if you would like to really bypass everything, you have to use:
@BypassValidationController(@ViewId(all = true))
instead.
2) bypassed extval-validation for every property bound via: #{personPage2.person ...}
but only for the view-id "/pages/new_person2.xhtml" + the given condition is true.
it's important to mention that the 4 possible targets for @BypassValidationController are optional. e.g. it's possible to annotate a property without annotating the class itself. furthermore, there are useful default values for all attributes.