fix: Update frappe.link_search usage
refer https://github.com/frappe/frappe/pull/22745
This commit is contained in:
parent
08aec7f6d7
commit
2790ae0744
@ -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}));
|
||||
});
|
||||
}
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user