[fix] patches

This commit is contained in:
Rushabh Mehta 2015-02-25 15:55:57 +05:30
parent 2a21bc9fc2
commit 6cdfd1e976
3 changed files with 11 additions and 2 deletions

View File

@ -217,7 +217,7 @@ class calculate_taxes_and_totals(object):
tax.grand_total_for_current_item = flt(item.net_amount + current_tax_amount, tax.precision("total"))
else:
tax.grand_total_for_current_item = \
flt(self.doc.get("taxes")[i-1].grand_total_for_current_item + current_tax_amount, tax.precision("total_taxes_and_charges"))
flt(self.doc.get("taxes")[i-1].grand_total_for_current_item + current_tax_amount, tax.precision("total"))
# in tax.total, accumulate grand total of each item
tax.total += tax.grand_total_for_current_item

View File

@ -126,4 +126,4 @@ erpnext.patches.v5_0.item_patches
erpnext.patches.v5_0.update_journal_entry_title
erpnext.patches.v5_0.taxes_and_totals_in_party_currency
erpnext.patches.v5_0.replace_renamed_fields_in_custom_scripts_and_print_formats
execute:frappe.db.sql("update `tabStock Entry` set from_bom = if(ifnull(bom_no, '')='', 0, 1)")
erpnext.patches.v5_0.update_from_bom

View File

@ -0,0 +1,9 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
frappe.reload_doctype("BOM")
frappe.db.sql("update `tabStock Entry` set from_bom = if(ifnull(bom_no, '')='', 0, 1)")