Support Forum
Support › MB Admin Columns › Admin column for Checkbox ListResolved
Is there an issue with showing an Admin Column for a Checkbox List selection? i have a group with a single top-level Checkbox List field with three options, i've enabled Admin Columns in the AIO extensions and for the field itself, given it a custom column title, and set it to filterable. Nothing. What am i doing wrong?
Hello Andrew,
I don't see that issue on my demo site, screenshot https://imgur.com/pwN5ePG
You can export the field group to a JSON file and share it here. I will help you to check the issue.
And please note that, the filterable feature only works with the taxonomy
field. Read more in the documentation https://docs.metabox.io/extensions/mb-admin-columns/
Hi Peter!
Thanks for taking a look at this.
{
"post_type": "meta-box",
"post_title": "Product line",
"post_date": "2023-08-18 20:16:24",
"post_status": "publish",
"post_content": "",
"settings": {
"object_type": "post",
"post_types": [
"product"
],
"context": "side",
"priority": "high",
"style": "default",
"tab_style": "",
"tab_default_active": "",
"class": "",
"prefix": "",
"text_domain": "your-text-domain",
"function_name": "your_prefix_function_name"
},
"fields": {
"checkbox_list_pepuiqyfikc": {
"_id": "checkbox_list_pepuiqyfikc",
"name": "Product line",
"id": "product_line",
"type": "checkbox_list",
"label_description": "",
"desc": "",
"options": "Olive\r\nSnail\r\nHyaluronic",
"std": "",
"min_clone": "",
"max_clone": "",
"add_button": "",
"admin_columns": {
"enable": true,
"position": {
"type": "after",
"column": "Categories"
},
"title": "",
"before": "",
"after": "",
"sort": true,
"link": "edit"
},
"columns": 12,
"before": "",
"after": "",
"class": "",
"sanitize_callback": "",
"save_field": true
}
},
"data": [],
"meta_box": {
"title": "Product line",
"id": "product-line",
"post_types": [
"product"
],
"context": "side",
"text_domain": "your-text-domain",
"function_name": "your_prefix_function_name",
"fields": [
{
"name": "Product line",
"id": "product_line",
"type": "checkbox_list",
"options": {
"Olive": "Olive",
"Snail": "Snail",
"Hyaluronic": "Hyaluronic"
},
"admin_columns": {
"position": "after Categories",
"sort": true,
"link": "edit"
}
}
]
}
}
could you also explain why i have a default '_id'? how do i get rid of it?
Hello,
You should add the column ID instead of the column title to display the admin column, it should be product_cat
, not Categories
. Screenshot https://imgur.com/ep6eNHa
Regarding the default _id
field, it is a hidden-standard custom field of the field group when using the builder. We shouldn't touch this field or get rid of it.
great, thank you, that worked! silly me.
no, wait! i am trying to add a second MB admin column after a first one, and that's not working. what does work is if it is adjacent to a default woo column. but not if i'm trying to specify it's position in relation to another MB column. so: before default woo 'date' works, but after custom MB 'product_line' doesn't. i'm following your correction, to specify the column postion using the column ID, and i'm trying to put 'product_routine' AFTER 'product_line' but it doesn't work. putting 'product_routine' BEFORE woo 'date' does. can you have a look at this for me please?