[fix] get_party_gle_currency caching

This commit is contained in:
Anand Doshi 2015-10-22 19:32:56 +05:30
parent e3910d02a5
commit 0b93bdcf40

View File

@ -201,7 +201,8 @@ def get_party_gle_currency(party_type, party, company):
return existing_gle_currency[0][0] if existing_gle_currency else None
return frappe.local_cache("party_gle_currency", (party_type, party, company), generator)
return frappe.local_cache("party_gle_currency", (party_type, party, company), generator,
regenerate_if_none=True)
def validate_party_gle_currency(party_type, party, company, party_account_currency=None):
"""Validate party account currency with existing GL Entry's currency"""