ACF Migrate Issue
- This topic has 5 replies, 2 voices, and was last updated 2 years, 11 months ago by
Long Nguyen.
-
AuthorPosts
-
June 1, 2022 at 4:22 AM #36262
Paul Middleton
ParticipantI just tried to use the ACF Migrate tool, but after it completed I checked some of the custom post fields, and a number of them were read only. No setting I could see marking them as such, but they were greyed out and you can't actually open dropdowns or type in text fields. Not all the fields were like that, but I didn't see a particular pattern to why some worked and some didn't. Per the instructions on the ACF Migrate screen, since there was an issue I restored a backup and am reporting the issue here. Any idea what might have been causing this?
June 1, 2022 at 12:43 PM #36267Long Nguyen
ModeratorHi,
Can you please share the generated code of the field group after migrating from ACF? Refer to this documentation https://docs.metabox.io/extensions/meta-box-builder/#getting-php-code
and some screenshots of the issue on your site.
June 2, 2022 at 1:35 AM #36280Paul Middleton
ParticipantHere's the code:
<?php add_filter( 'rwmb_meta_boxes', 'resource_data' ); function resource_data( $meta_boxes ) { $prefix = ''; $meta_boxes[] = [ 'title' => __( 'Resource Data', 'oslc' ), 'id' => 'acf_group_53e11a12c9378', 'post_types' => ['resource', 'attachment'], 'fields' => [ [ 'name' => __( 'Authors', 'oslc' ), 'id' => $prefix . 'authors', 'type' => 'group', 'clone' => true, 'sort_clone' => true, 'max_clone' => 0, 'add_button' => __( 'Add Row', 'oslc' ), 'fields' => [ [ 'name' => __( 'Author Type', 'oslc' ), 'id' => $prefix . 'author_type', 'type' => 'select', 'options' => [ 'scientist' => __( 'OSLC Scientist', 'oslc' ), 'other' => __( 'Other', 'oslc' ), ], 'std' => 'scientist', 'required' => true, ], [ 'name' => __( 'OSLC Scientist', 'oslc' ), 'id' => $prefix . 'scientist', 'type' => 'post', 'post_type' => ['scientist'], 'visible' => [ 'when' => [['author_type', '=', 'scientist']], 'relation' => 'and', ], ], [ 'name' => __( 'Other', 'oslc' ), 'id' => $prefix . 'other', 'type' => 'text', 'visible' => [ 'when' => [['author_type', '=', 'other']], 'relation' => 'and', ], ], ], ], [ 'name' => __( 'Attachment Type', 'oslc' ), 'id' => $prefix . 'attachment_type', 'type' => 'select', 'options' => [ 'File' => __( 'File', 'oslc' ), 'Link' => __( 'Link', 'oslc' ), ], 'placeholder' => __( '- Select -', 'oslc' ), ], [ 'name' => __( 'File', 'oslc' ), 'id' => $prefix . 'file', 'type' => 'file_advanced', 'max_file_uploads' => 1, 'visible' => [ 'when' => [['attachment_type', '=', 'File']], 'relation' => 'and', ], 'max_status' => false, ], [ 'name' => __( 'Link Text', 'oslc' ), 'id' => $prefix . 'link_text', 'type' => 'text', 'visible' => [ 'when' => [['attachment_type', '=', 'Link']], 'relation' => 'and', ], ], [ 'name' => __( 'Link URL', 'oslc' ), 'id' => $prefix . 'link_url', 'type' => 'text', 'visible' => [ 'when' => [['attachment_type', '=', 'Link']], 'relation' => 'and', ], ], ], ]; return $meta_boxes; }
And here's a screenshot of the fields not being editable:
June 3, 2022 at 12:40 PM #36308Long Nguyen
ModeratorHi,
Thanks for your additional information.
Please share your site credentials via this contact form https://metabox.io/contact/, I will take a closer look.
June 4, 2022 at 2:12 AM #36323Paul Middleton
ParticipantOk, I've submitted login info for a staging site where you can check things out.
June 9, 2022 at 9:50 AM #36381Long Nguyen
ModeratorResolve the issue by re-save the field group.
Have a nice day. -
AuthorPosts
- You must be logged in to reply to this topic.