Merge pull request #3287 from rmehta/customer-fix
Customer fix
diff --git a/erpnext/__version__.py b/erpnext/__version__.py
index 6d0efc7..fb2733c 100644
--- a/erpnext/__version__.py
+++ b/erpnext/__version__.py
@@ -1,2 +1,2 @@
from __future__ import unicode_literals
-__version__ = 'v5.0.0'
+__version__ = '5.0.1'
diff --git a/erpnext/accounts/report/financial_statements.py b/erpnext/accounts/report/financial_statements.py
index 8a954a6..88d1beb 100644
--- a/erpnext/accounts/report/financial_statements.py
+++ b/erpnext/accounts/report/financial_statements.py
@@ -224,20 +224,6 @@
roots.sort(compare_roots)
-def sort_root_accounts(roots):
- """Sort root types as Asset, Liability, Equity, Income, Expense"""
-
- def compare_roots(a, b):
- if a.report_type != b.report_type and a.report_type == "Balance Sheet":
- return -1
- if a.root_type != b.root_type and a.root_type == "Asset":
- return -1
- if a.root_type == "Liability" and b.root_type == "Equity":
- return -1
- return 1
-
- roots.sort(compare_roots)
-
def get_gl_entries(company, from_date, to_date, root_lft, root_rgt, ignore_closing_entries=False):
"""Returns a dict like { "account": [gl entries], ... }"""
additional_conditions = []
diff --git a/erpnext/hooks.py b/erpnext/hooks.py
index 1599218..d8d8850 100644
--- a/erpnext/hooks.py
+++ b/erpnext/hooks.py
@@ -5,7 +5,7 @@
app_description = "Open Source Enterprise Resource Planning for Small and Midsized Organizations"
app_icon = "icon-th"
app_color = "#e74c3c"
-app_version = "v5.0.0"
+app_version = "5.0.1"
error_report_email = "support@erpnext.com"
diff --git a/erpnext/patches/v4_2/repost_requested_qty.py b/erpnext/patches/v4_2/repost_requested_qty.py
deleted file mode 100644
index 8c1d6f7..0000000
--- a/erpnext/patches/v4_2/repost_requested_qty.py
+++ /dev/null
@@ -1,21 +0,0 @@
-# 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():
- from erpnext.utilities.repost_stock import update_bin_qty, get_indented_qty
-
- count=0
- for item_code, warehouse in frappe.db.sql("""select distinct item_code, warehouse
- from `tabMaterial Request Item` where docstatus = 1"""):
- try:
- count += 1
- update_bin_qty(item_code, warehouse, {
- "indented_qty": get_indented_qty(item_code, warehouse),
- })
- if count % 200 == 0:
- frappe.db.commit()
- except:
- frappe.db.rollback()
diff --git a/erpnext/patches/v4_2/update_advance_paid.py b/erpnext/patches/v4_2/update_advance_paid.py
deleted file mode 100644
index 818735a..0000000
--- a/erpnext/patches/v4_2/update_advance_paid.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# 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():
- for dt in ("Sales Order", "Purchase Order"):
- orders_with_advance = frappe.db.sql("""select name from `tab{0}`
- where docstatus < 2 and ifnull(advance_paid, 0) != 0""".format(dt), as_dict=1)
-
- for order in orders_with_advance:
- frappe.get_doc(dt, order.name).set_total_advance_paid()
\ No newline at end of file
diff --git a/erpnext/stock/report/batch_wise_balance_history/batch_wise_balance_history.py b/erpnext/stock/report/batch_wise_balance_history/batch_wise_balance_history.py
index c6ef82f..d911975 100644
--- a/erpnext/stock/report/batch_wise_balance_history/batch_wise_balance_history.py
+++ b/erpnext/stock/report/batch_wise_balance_history/batch_wise_balance_history.py
@@ -7,9 +7,7 @@
from frappe.utils import flt, cint, getdate
def execute(filters=None):
- if not filters: filters = {}
-
- float_precision = cint(frappe.db.get_default("float_precision")) or 3
+ if not filters: filters = {}
float_precision = cint(frappe.db.get_default("float_precision")) or 3
diff --git a/setup.py b/setup.py
index 6ed8378..13ddbed 100644
--- a/setup.py
+++ b/setup.py
@@ -1,6 +1,6 @@
from setuptools import setup, find_packages
-version = "v5.0.0"
+version = "5.0.1"
with open("requirements.txt", "r") as f:
install_requires = f.readlines()