From 2790ae07443381ec4b2b23d645bc52e98fdf9ee4 Mon Sep 17 00:00:00 2001 From: Ankush Menat Date: Mon, 16 Oct 2023 15:43:14 +0530 Subject: [PATCH] fix: Update frappe.link_search usage refer https://github.com/frappe/frappe/pull/22745 --- erpnext/public/js/utils/item_selector.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/erpnext/public/js/utils/item_selector.js b/erpnext/public/js/utils/item_selector.js index 9fc264086a..e74d291acd 100644 --- a/erpnext/public/js/utils/item_selector.js +++ b/erpnext/public/js/utils/item_selector.js @@ -97,14 +97,14 @@ erpnext.ItemSelector = class ItemSelector { } var me = this; - frappe.link_search("Item", args, function(r) { - $.each(r.values, function(i, d) { + frappe.link_search("Item", args, function(results) { + $.each(results, function(i, d) { if(!d.image) { d.abbr = frappe.get_abbr(d.item_name); d.color = frappe.get_palette(d.item_name); } }); - me.dialog.results.html(frappe.render_template('item_selector', {'data':r.values})); + me.dialog.results.html(frappe.render_template('item_selector', {'data': results})); }); } };