From dea3fb0d64e3be5d73893de18caf2083b7990605 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Thu, 5 Feb 2015 15:05:58 +0530 Subject: [PATCH] [fix] call calculate code only once after applying pricing rule --- erpnext/public/js/transaction.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/erpnext/public/js/transaction.js b/erpnext/public/js/transaction.js index 6d38b46b78..e1e78a3c01 100644 --- a/erpnext/public/js/transaction.js +++ b/erpnext/public/js/transaction.js @@ -404,23 +404,27 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({ _set_values_for_item_list: function(children) { var me = this; var price_list_rate_changed = false; - $.each(children, function(i, d) { + for(var i=0, l=children.length; i