-
Notifications
You must be signed in to change notification settings - Fork 67
Open
Description
When attempting to use conditional logic based on a checkbox, showing a sibling field when the checkbox is checked works as expected. However, only showing a field when the checkbox is unchecked does not:
Field::make_checkbox( 'curate_selection', _x( 'Curate the selection?', 'custom field label', 'xxx' ) )
->set_option_value( true ),
Field::make_association( 'da_resource_types', __( 'DA Resource Types', 'scustom field label', 'xxx' ) )
->set_conditional_logic( array(
array(
'field' => 'curate_selection',
'value' => false,
),
) )
->set_types( array(
array(
'type' => 'term',
'taxonomy' => 'da_resource_type',
),
) ),
Field::make_association( 'da_resources', __( 'DA Resources', 'custom field label', 'xxx' ) )
->set_max( 3 )
->set_conditional_logic( array(
array(
'field' => 'curate_selection',
'value' => true,
),
) )
->set_types( array(
array(
'type' => 'post',
'post_type' => 'da_resource',
),
) )
Metadata
Metadata
Assignees
Labels
No labels