mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-16 11:39:18 +00:00
[fix] patches
This commit is contained in:
@@ -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"))
|
tax.grand_total_for_current_item = flt(item.net_amount + current_tax_amount, tax.precision("total"))
|
||||||
else:
|
else:
|
||||||
tax.grand_total_for_current_item = \
|
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
|
# in tax.total, accumulate grand total of each item
|
||||||
tax.total += tax.grand_total_for_current_item
|
tax.total += tax.grand_total_for_current_item
|
||||||
|
|||||||
@@ -126,4 +126,4 @@ erpnext.patches.v5_0.item_patches
|
|||||||
erpnext.patches.v5_0.update_journal_entry_title
|
erpnext.patches.v5_0.update_journal_entry_title
|
||||||
erpnext.patches.v5_0.taxes_and_totals_in_party_currency
|
erpnext.patches.v5_0.taxes_and_totals_in_party_currency
|
||||||
erpnext.patches.v5_0.replace_renamed_fields_in_custom_scripts_and_print_formats
|
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
|
||||||
|
|||||||
9
erpnext/patches/v5_0/update_from_bom.py
Normal file
9
erpnext/patches/v5_0/update_from_bom.py
Normal 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)")
|
||||||
Reference in New Issue
Block a user