Merge pull request #44098 from frappe/mergify/bp/version-15-hotfix/pr-44065

fix: update payment amount for partial pos return (backport #44065)
This commit is contained in:
ruthra kumar
2024-11-12 10:10:58 +05:30
committed by GitHub

View File

@@ -844,13 +844,13 @@ erpnext.taxes_and_totals = class TaxesAndTotals extends erpnext.payments {
); );
} }
if(!this.frm.doc.is_return){ this.frm.doc.payments.find(payment => {
this.frm.doc.payments.find(payment => { if (payment.default) {
if (payment.default) { payment.amount = total_amount_to_pay;
payment.amount = total_amount_to_pay; } else {
} payment.amount = 0
}); }
} });
this.frm.refresh_fields(); this.frm.refresh_fields();
} }