How can I remove item_group and brand columns from table…
For your better understanding, My code
frappe.ui.form.on('Purchase Order', {
get_item(frm) {
const dialog = new frappe.ui.form.MultiSelectDialog({
doctype: "Item",
target: frm,
setters: {
item_name: null,
item_group: null,
brand: null
},
add_filters_group: 1,
action(selections) {
if (selections && selections.length > 0) {
selections.forEach(selection => {
if (!frm.doc.items) {
frm.doc.items = [];
}
frm.doc.items.push({"item_code": selection});
});
frm.refresh_field("items");
} else {
frappe.msgprint(__('No items selected'));
}
dialog.dialog.hide();
},
size: 'large'
});
}
});```