Skip to content

Commit

Permalink
fix: codacy fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
vishdha committed Sep 30, 2020
1 parent 49e1f16 commit 92fcf3d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 2 additions & 1 deletion erpnext/public/js/controllers/taxes_and_totals.js
Original file line number Diff line number Diff line change
Expand Up @@ -778,8 +778,9 @@ erpnext.taxes_and_totals = erpnext.payments.extend({
callback: (r) => {
if (r.message) {
let taxes = me.frm.doc.taxes;
// get tax account head from company master to avoid disorder behaviour and remove it from taxes table.
frappe.db.get_value('Company', { "name": me.frm.doc.company }, ["default_cultivation_tax_account_flower", "default_cultivation_tax_account_leaf", "default_cultivation_tax_account_plant"], (r) => {
let tax_account_list = [r.default_cultivation_tax_account_flower, r.default_cultivation_tax_account_leaf, r.default_cultivation_tax_account_plant]
let tax_account_list = [r.default_cultivation_tax_account_flower, r.default_cultivation_tax_account_leaf, r.default_cultivation_tax_account_plant];
if (taxes && taxes.length > 0) {
$.each(taxes, function (i, tax) {
if (tax_account_list.indexOf(tax.account_head) !== -1) {
Expand Down
1 change: 0 additions & 1 deletion erpnext/public/js/controllers/transaction.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ erpnext.TransactionController = erpnext.taxes_and_totals.extend({
frm.cscript.set_and_update_cultivation_tax();
},
qty: function(frm, cdt, cdn) {
console.log("test")
frm.cscript.set_and_update_cultivation_tax();
}
});
Expand Down

0 comments on commit 92fcf3d

Please sign in to comment.