Hello,
I am having an issue with conditional logic used in a clonable group field. The logic does not apply to clones, it only applies to the default group.
Here is the code I am using:
<?php
add_filter( 'rwmb_meta_boxes', 'your_prefix_function_name' );
function your_prefix_function_name( $meta_boxes ) {
$prefix = '';
$meta_boxes[] = [
'id' => 105,
'post_types' => ['part'],
'fields' => [
[
'name' => __( 'Group', 'your-text-domain' ),
'id' => $prefix . 'group_hlso8r8au9',
'type' => 'group',
'clone' => true,
'clone_default' => true,
'fields' => [
[
'name' => __( 'Select', 'your-text-domain' ),
'id' => $prefix . 'select_e8av28xu5t4',
'type' => 'select',
'options' => [
'yes' => __( 'Yes', 'your-text-domain' ),
'no' => __( 'No', 'your-text-domain' ),
],
'std' => 'no',
],
[
'name' => __( 'Text', 'your-text-domain' ),
'id' => $prefix . 'text_r1urjedt9w',
'type' => 'text',
'visible' => [
'when' => [['select_e8av28xu5t4', '=', 'yes']],
'relation' => 'or',
],
],
],
],
],
];
return $meta_boxes;
}
And the video:
https://watch.screencastify.com/v/Bco0JG5Hfnq12nrCviXW
Could you investigate the issue or instruct me on what I am doing wrong?
Thank you in advance