From 4f3b7da9baea791d2f5bb2731989e730ba491c2f Mon Sep 17 00:00:00 2001 From: Rohit Waghchaure Date: Tue, 15 Sep 2020 14:47:36 +0530 Subject: [PATCH 1/2] fix: set_taxes() missing 1 required positional argument: 'company' --- erpnext/public/js/utils/party.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/erpnext/public/js/utils/party.js b/erpnext/public/js/utils/party.js index 065326744c..af1f433514 100644 --- a/erpnext/public/js/utils/party.js +++ b/erpnext/public/js/utils/party.js @@ -224,6 +224,10 @@ erpnext.utils.set_taxes = function(frm, triggered_from_field) { party = frm.doc.party_name; } + if (!frm.doc.company) { + frappe.throw(_("Kindly select the company first")); + } + frappe.call({ method: "erpnext.accounts.party.set_taxes", args: { From 0aff6d83af06f56bcbf30986b5659247754250f5 Mon Sep 17 00:00:00 2001 From: Deepesh Garg <42651287+deepeshgarg007@users.noreply.github.com> Date: Sat, 19 Sep 2020 18:05:58 +0530 Subject: [PATCH 2/2] Update erpnext/public/js/utils/party.js Co-authored-by: Sagar Vora --- erpnext/public/js/utils/party.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/erpnext/public/js/utils/party.js b/erpnext/public/js/utils/party.js index af1f433514..44e75aee36 100644 --- a/erpnext/public/js/utils/party.js +++ b/erpnext/public/js/utils/party.js @@ -225,7 +225,7 @@ erpnext.utils.set_taxes = function(frm, triggered_from_field) { } if (!frm.doc.company) { - frappe.throw(_("Kindly select the company first")); + frappe.throw(__("Kindly select the company first")); } frappe.call({ @@ -296,4 +296,4 @@ erpnext.utils.get_shipping_address = function(frm, callback){ } else { frappe.msgprint(__("Select company first")); } -} \ No newline at end of file +}