Sometimes, item_data.modifier_list_info.min_selected_modifiers and item_data.modifier_list_info.max_selected_modifiers show wrong value in seller dashboard

in catalog object, item_data.modifier_list_info.min_selected_modifiers and item_data.modifier_list_info.max_selected_modifiers are not display correctly in seller dashboard.
for example, sellder dashboard show their values are 1 and 1, but when to fetch data through api, their values are -1 and -1. after change value in seller dashboard, e.g., from 1 to 2. api returns correct value 2.

The value -1 is the default value for new modifiers when returned by the API. What value were you expecting to see returned with the API? :slightly_smiling_face:

it’s ok to set -1 as default value. but in seller board, it shows 1. it makes confused for operator

If it’s set to 1 then 1 should be returned in the response. If it’s set to none in the seller Dashboard it’ll be -1. :slightly_smiling_face:



please see two pics above, modifier_list_id = 3XAMQECLH4SP5DDFRYMT6MB6, in api, it shows min_selected_modifiers -1 and max_selected_modifiers -1. but in seller board, it shows 1 and 1. I think it’s a bug. please hande as soon as possible

When retrieve the ITEM the modifier is applied to what’s the value? :slightly_smiling_face:

  1. the item with modifier created in sellboard manually;
  2. we do not apply value to item_data.modifier_list_info.min_selected_modifiers and item_data.modifier_list_info.max_selected_modifiers, we only retrieve data from square;

addtionally, i find on the site Brown Sugar Boba & Mochi Black Milk Tea | Ume Tea, the page show correct value. please see below:


item with name = ‘Brown Sugar Boba & Mochi Black Milk Tea’ and id = ‘6FRW5F2VX3ZMG2V2URFCM72M’ has modifier list with name = ‘Cane Sugar(FCM)’ and id = ‘3XAMQECLH4SP5DDFRYMT6MB6’, and the modifier list shows required.
why does it show required?

from api /v2/catalog/object/6FRW5F2VX3ZMG2V2URFCM72M, item_data.modifier_list_info.min_selected_modifiers and item_data.modifier_list_info.max_selected_modifiers for the modifier list with id = ‘3XAMQECLH4SP5DDFRYMT6MB6’ are -1 both.

could you explain why it show required on the site? what data supports it?

If you retrieve the modifier 3XAMQECLH4SP5DDFRYMT6MB6 you’ll see on_by_default is set to true. If true , this CatalogModifier should be selected by default for this CatalogItem . This is why your seeing Required.

The min max is still set to -1 cause they weren’t set when the modifier was created an it’s at its default -1 which represents 0 by default. :slightly_smiling_face:

  1. is on_by_default field modifier_list_data.modifiers.modifier_data.on_by_default ?
  2. when item_data.modifier_list_info.min_selected_modifiers and item_data.modifier_list_info.max_selected_modifiers are both -1, does it mean that the modifier list is applied to the item and isn’t modified in item yet?

For 1 yes. For your second question when the modifier is included in the returned object that means that the list applies to the item. The -1 is just the default value for when there isn’t a min max set by the seller. :slightly_smiling_face: