Hello, I’m trying to filter items field on webform to show only items with specific item groups
I tried the following code but didn’t work, any ideas of how to do that ?!
frappe.web_form.on(“web_form”, “onload”, function(frm) {
frm.set_query(“item”, function() {
return {
filters: {
item_group: [‘in’, [‘item_group1’, ‘item_group2’, ‘item_group3’]]
}
};
});
})