Joe Link
Well-known member
I've got an @AddonsLab filter group with a condition that changes depending on which other filters are selected. I'm trying to target closed_perm so I can make changes only when that filter option is selected (I only want to show businesses which are permanently closed when the filter is selected, otherwise hide).
When only that option is selected it's $__globals.filterSet.link_rms_item_options.0.closed_perm
When other filters are selected it changes, in this case it's $__globals.filterSet.link_rms_item_options.2.closed_perm
Something like this would work, but it's ugly.
Is there a cleaner way to do it, maybe with in_array or some other wildcard option I'm not aware of?
When only that option is selected it's $__globals.filterSet.link_rms_item_options.0.closed_perm
When other filters are selected it changes, in this case it's $__globals.filterSet.link_rms_item_options.2.closed_perm
Something like this would work, but it's ugly.
Code:
<xf:if is="$__globals.filterSet.link_rms_item_options.0 == 'closed_perm' OR
$__globals.filterSet.link_rms_item_options.1 == 'closed_perm' OR
$__globals.filterSet.link_rms_item_options.2 == 'closed_perm' OR
$__globals.filterSet.link_rms_item_options.3 == 'closed_perm'">
Is there a cleaner way to do it, maybe with in_array or some other wildcard option I'm not aware of?