Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
what i try to to is this:
open a field if checkboxes A+B are checked. But it doesnt work via conditionals. Field appears when only one of the checkboxes is checked. But i set the condition that this should happens only when both are checked (see screenshots).
best,
Comment | File | Size | Author |
---|---|---|---|
#11 | conditionals_with-2855258-11.patch | 2.52 KB | jrockowitz |
| |||
#9 | conditionals_with-2855258-9.patch | 1.93 KB | jrockowitz |
#6 | webform.JPG | 33.38 KB | vgutekunst |
#2 | conditionals_with-2855258-2.patch | 1.26 KB | jrockowitz |
| |||
webform2.JPG | 17.89 KB | vgutekunst |
Comments
Comment #2
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedThe attached patch adds the below example of multiple checkboxes being used as trigger to 'Example: Elements: Condition Logic' (form/example-elements-states)
Comment #4
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedI committed the working example. Please checkout the latest dev release and review.
Comment #5
vgutekunst CreditAttribution: vgutekunst commentedyoure crazy fast and good!
i checked it and i can confirm it works with element "textarea" but not with element "message".
here the yaml
Comment #6
vgutekunst CreditAttribution: vgutekunst commentedComment #7
vgutekunst CreditAttribution: vgutekunst commentedComment #8
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedI can duplicate the issue. The below code...
...is being converted via the UI to...
which is being interpreted as an 'or' instead of an 'and' operator.
Comment #9
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedComment #11
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedComment #13
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedFixed. Pleas checkout or download the latest dev release.
Comment #14
vgutekunst CreditAttribution: vgutekunst commentedIt works! Thank you very much jrockowitz!