I'm currently developing a dynamic form system and have to implement a feature, where users (who set which form fields should be displayed from some predefined fields) must have the ability to define which input fields are required and which not. There also has to be the possibility to set the following: "Field A and B should be displayed. You need to fill out at least one of them (A or B, or if you want A and B) to submit the form."
I have stored following data:
0: not displayed
1: displayed
2: displayed and required (w/o any dependency to another field)
greater than 1: Custom identifier
Example:
name: 1
birthday: 2
city: 2
x: 3
y: 3
postal code: 0
With that setting the user has to fill out the name, either birthday or city and either x or y.
Does JSF support that kind of a "required" field?
Regards