fix: use correct date value
This commit is contained in:
@@ -398,7 +398,7 @@ def update_outstanding_amt(
|
||||
def validate_frozen_account(company, account, adv_adj=None):
|
||||
frozen_account = frappe.get_cached_value("Account", account, "freeze_account")
|
||||
if frozen_account == "Yes" and not adv_adj:
|
||||
role_allowed_for_frozen_entries = frappe.db.get_cached_value(
|
||||
role_allowed_for_frozen_entries = frappe.get_cached_value(
|
||||
"Company", company, "role_allowed_for_frozen_entries"
|
||||
)
|
||||
|
||||
|
||||
@@ -80,7 +80,7 @@ class TestProcessDeferredAccounting(IntegrationTestCase):
|
||||
|
||||
|
||||
def change_acc_settings(
|
||||
company="_Test Company", acc_frozen_till_date="", book_deferred_entries_based_on="Days"
|
||||
company="_Test Company", acc_frozen_till_date=None, book_deferred_entries_based_on="Days"
|
||||
):
|
||||
acc_settings = frappe.get_doc("Accounts Settings", "Accounts Settings")
|
||||
acc_settings.book_deferred_entries_based_on = book_deferred_entries_based_on
|
||||
|
||||
@@ -805,7 +805,7 @@ def validate_party_frozen_disabled(company, party_type, party_name):
|
||||
if party.disabled:
|
||||
frappe.throw(_("{0} {1} is disabled").format(party_type, party_name), PartyDisabled)
|
||||
elif party.get("is_frozen"):
|
||||
role_allowed_for_frozen_entries = frappe.db.get_cached_value(
|
||||
role_allowed_for_frozen_entries = frappe.get_cached_value(
|
||||
"Company", company, "role_allowed_for_frozen_entries"
|
||||
)
|
||||
if role_allowed_for_frozen_entries not in frappe.get_roles():
|
||||
|
||||
Reference in New Issue
Block a user