diff --git a/erpnext/selling/doctype/customer/customer.js b/erpnext/selling/doctype/customer/customer.js index 1994bd31e7..25c3cd22ec 100644 --- a/erpnext/selling/doctype/customer/customer.js +++ b/erpnext/selling/doctype/customer/customer.js @@ -47,11 +47,11 @@ frappe.ui.form.on("Customer", { frappe.call({ doc: frm.doc, args: { - "address_title":frm.doc.customer_primary_address + "address_title": frm.doc.customer_primary_address }, - method: 'get_display', + method: 'frappe.contacts.doctype.address.address.get_address_display', callback: function(r) { - frm.set_value("primary_address",r.message); + frm.set_value("primary_address", r.message); } }); } diff --git a/erpnext/selling/doctype/customer/customer.py b/erpnext/selling/doctype/customer/customer.py index 518952f424..6f25bf7fd6 100644 --- a/erpnext/selling/doctype/customer/customer.py +++ b/erpnext/selling/doctype/customer/customer.py @@ -77,11 +77,6 @@ class Customer(TransactionBase): if self.flags.is_new_doc and self.get('address_line1'): make_address(self) - @classmethod - def get_display(self,address_title): - from frappe.contacts.doctype.address.address import get_address_display - return get_address_display(address_title) - def update_lead_status(self): '''If Customer created from Lead, update lead status to "Converted" update Customer link in Quotation, Opportunity'''