refactor: set default for fetch methods

This commit is contained in:
ruthra kumar
2025-05-05 13:58:08 +05:30
parent 204d1d6a53
commit fc793f0f25
2 changed files with 5 additions and 3 deletions

View File

@@ -49,9 +49,10 @@ class ReceivablePayableReport:
self.age_as_on = (
getdate(nowdate()) if self.filters.report_date > getdate(nowdate()) else self.filters.report_date
)
self.ple_fetch_method = frappe.db.get_single_value(
"Accounts Settings", "receivable_payable_fetch_method"
)
self.ple_fetch_method = (
frappe.db.get_single_value("Accounts Settings", "receivable_payable_fetch_method")
or "Buffered Cursor"
) # Fail Safe
def run(self, args):
self.filters.update(args)

View File

@@ -373,3 +373,4 @@ execute:frappe.db.set_single_value("Accounts Settings", "exchange_gain_loss_post
erpnext.patches.v14_0.update_posting_datetime
erpnext.stock.doctype.stock_ledger_entry.patches.ensure_sle_indexes
erpnext.patches.v14_0.rename_group_by_to_categorize_by
execute:frappe.db.set_single_value("Accounts Settings", "receivable_payable_fetch_method", "Buffered Cursor")