fix: Additonal discount not get set in sales transactions

This commit is contained in:
deepeshgarg007 2019-07-04 15:56:34 +05:30
parent 29734dae18
commit a9ea49c976

View File

@ -145,6 +145,11 @@ erpnext.selling.SellingController = erpnext.TransactionController.extend({
},
discount_amount: function(doc, cdt, cdn) {
if(doc.name === cdn) {
return;
}
var item = frappe.get_doc(cdt, cdn);
item.discount_percentage = 0.0;
this.apply_discount_on_item(doc, cdt, cdn, 'discount_amount');