fix: Validation Error message on Prepared Report. (#19639)

Give the user the reason why he has to use filters.
This commit is contained in:
Marica 2019-11-22 14:38:58 +05:30 committed by Nabin Hait
parent 7ca472780b
commit b5c296da9e

View File

@ -292,7 +292,7 @@ def validate_filters(filters):
if not (filters.get("item_code") or filters.get("warehouse")):
sle_count = flt(frappe.db.sql("""select count(name) from `tabStock Ledger Entry`""")[0][0])
if sle_count > 500000:
frappe.throw(_("Please set filter based on Item or Warehouse"))
frappe.throw(_("Please set filter based on Item or Warehouse due to a large amount of entries."))
def get_variants_attributes():
'''Return all item variant attributes.'''