Hi!
Sorry što je na engleskom, ali postao sam na još jedan forum :D
Al tko zna, zna :D
I'm trying to create dependence between checkbox & textbox. If checkbox is selected textbox should be required to fill. If not it can be empty.
I created xhtml like this:
<tr:inputText id="email"
labelAndAccessKey="#{msg['subscriber.package.email']}"
value="#{createBean.subscriber.email}"
contentStyle="width: 200px;" maximumLength=""
validator="#{Validator.validateEmail}"
required="#{createBean.mobileAccessWeb}"
renderer="#{createBean.isMobileAccessWeb}"
partialTriggers="mobileAccessWeb">
<tr:selectBooleanCheckbox
labelAndAccessKey="#{msg['msg.webAccess']}:"
id="mobileAccessWeb" immediate="true" autoSubmit="true"
valueChangeListener="#{createBean.onChangeMobileAccessWeb}"
value="#{createBean.mobileAccessWeb}" />
But if I dont use checkbox (it is false) after loading and click save - it is possible. If I select checkbox and enter data in email field and click save - it is possible. If I select checkbox and deselect it - I got message: E-Mail - You must enter a value.
Tried on google, but with no success.
Thanks for answer!
Regards, Mile