[fix] On change of payment terms template, not fetch respective schedule data (#11928)

This commit is contained in:
rohitwaghchaure 2017-12-11 14:54:20 +05:30 committed by Nabin Hait
parent 505661b5c0
commit efbc0667ec
2 changed files with 2 additions and 2 deletions

View File

@ -705,7 +705,7 @@ class AccountsController(TransactionBase):
total_portion += flt(term.get('invoice_portion', 0))
if flt(total_portion, 2) != 100.00:
frappe.throw(_('Combined invoice portion must equal 100%'), indicator='red')
frappe.msgprint(_('Combined invoice portion must equal 100%'), indicator='red', raise_exception=1)
def is_rounded_total_disabled(self):
if self.meta.get_field("disable_rounded_total"):

View File

@ -1186,7 +1186,7 @@ erpnext.TransactionController = erpnext.taxes_and_totals.extend({
payment_terms_template: function() {
var me = this;
if(this.frm.doc.payment_terms_template && !this.frm.doc.payment_schedule) {
if(this.frm.doc.payment_terms_template) {
frappe.call({
method: "erpnext.controllers.accounts_controller.get_payment_terms",
args: {