Skip to content

Commit

Permalink
fix: minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Ninad1306 committed Aug 13, 2024
1 parent fc2b42e commit 6417b1a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ class TaxesController {

const item_wise_tax_rates = JSON.parse(tax_row.item_wise_tax_rates || "{}");
return this.frm.doc.items.reduce((total, item) => {
return total + item.qty * item_wise_tax_rates[item.name];
return total + item.qty * (item_wise_tax_rates[item.name] || tax_row.rate);
}, 0);
}
}

0 comments on commit 6417b1a

Please sign in to comment.