Cleanup and fixes of payment terms feature

This commit is contained in:
Nabin Hait
2017-11-21 19:58:16 +05:30
parent 7fa111de45
commit 0551f7bb00
14 changed files with 131 additions and 196 deletions

View File

@@ -1153,7 +1153,7 @@ erpnext.TransactionController = erpnext.taxes_and_totals.extend({
args: {
terms_template: this.frm.doc.payment_terms_template,
posting_date: this.frm.doc.posting_date || this.frm.doc.transaction_date,
grand_total: this.frm.doc.grand_total
grand_total: this.frm.doc.rounded_total || this.frm.doc.grand_total
},
callback: function(r) {
if(r.message && !r.exc) {
@@ -1172,7 +1172,7 @@ erpnext.TransactionController = erpnext.taxes_and_totals.extend({
args: {
term: row.payment_term,
posting_date: this.frm.doc.posting_date || this.frm.doc.transaction_date,
grand_total: this.frm.doc.grand_total
grand_total: this.frm.doc.rounded_total || this.frm.doc.grand_total
},
callback: function(r) {
if(r.message && !r.exc) {