Try ERPNext Buy Support Partners Foundation

Auto Populating Item Variant Attributes Based on Item Group

Hi.

I am trying to auto-populate the Item Variant Attributes table on form Validation if the item group matches my criteria.

For example, if Item Group is “Buttons”, then set “Has Variants” to true and add a row to the Item Variant Attributes table saying variants are based on Colour.

I’m struggling with adding a row to the Item Variant Attributes table and setting the attribute as Colour. Any help would be appreciated!

Thanks in advance.