remove_default setting in Taxonomy field

Support General remove_default setting in Taxonomy field

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #41998
    Artem AArtem A
    Participant

    Hello,

    I'm trying to create metabox for one of the post types with Taxonomy field and remove_default setting enabled and it works as it should for post type which passed in post_types setting of this metabox, but after this default taxonomy metabox disappeared also from other post type screens where this taxonomy set.

    Code example:

    register_taxonomy( 'quiz', [ 'assignment', 'company' ] );

    ...

    [
    'title' => __( 'Options', 'site' ),
    'post_types' => 'company',
    'fields' => [
    [
    'id' => 'quiz',
    'type' => 'taxonomy',
    'name' => __( 'Quiz', 'site' ),
    'taxonomy' => 'quiz',
    'field_type' => 'radio_list',
    'remove_default' => true,
    ],
    ],

    Possible bug:
    There is no core Quiz metabox at edit screen of Assignment post type.

    Expected behavior:
    No core metabox Quiz at edit screen of Company post type but it should still be present at Assignment post type.

    Possible solution:
    Check current_screen vs post_types setting of Field array with settings in remove_default_meta_box method of RWMB_Taxonomy_Field class.

    #42006
    PeterPeter
    Moderator

    Hello,

    Thanks for your feedback. I can see that issue on my demo site. I've escalated this issue to the development team to fix it in the next update.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.