diff --git a/erpnext/public/js/utils/party.js b/erpnext/public/js/utils/party.js index 3a5a0624e8..fe2a992bc9 100644 --- a/erpnext/public/js/utils/party.js +++ b/erpnext/public/js/utils/party.js @@ -171,7 +171,7 @@ erpnext.utils.validate_mandatory = function(frm, label, value, trigger_on) { } erpnext.utils.get_shipping_address = function(frm, callback){ - if (frm.doc.company) { + if (frm.doc.company && !frm.doc.shipping_address) { frappe.call({ method: "frappe.contacts.doctype.address.address.get_shipping_address", args: { @@ -192,4 +192,4 @@ erpnext.utils.get_shipping_address = function(frm, callback){ } else { frappe.msgprint(__("Select company first")); } -} \ No newline at end of file +}