mirror of
https://github.com/eitchtee/WYGIWYH.git
synced 2026-04-26 02:28:35 +02:00
feat: improve transactions list loading time
Prefetch more values and allow them to be cached
This commit is contained in:
@@ -84,9 +84,12 @@ def transactions_list(request, month: int, year: int):
|
|||||||
"account__group",
|
"account__group",
|
||||||
"category",
|
"category",
|
||||||
"tags",
|
"tags",
|
||||||
|
"tags__id",
|
||||||
"account__exchange_currency",
|
"account__exchange_currency",
|
||||||
"account__currency",
|
"account__currency",
|
||||||
"installment_plan",
|
"installment_plan",
|
||||||
|
"entities__name",
|
||||||
|
"entities__id",
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -336,9 +336,12 @@ def transaction_all_list(request):
|
|||||||
"account__group",
|
"account__group",
|
||||||
"category",
|
"category",
|
||||||
"tags",
|
"tags",
|
||||||
|
"tags__id",
|
||||||
"account__exchange_currency",
|
"account__exchange_currency",
|
||||||
"account__currency",
|
"account__currency",
|
||||||
"installment_plan",
|
"installment_plan",
|
||||||
|
"entities__name",
|
||||||
|
"entities__id",
|
||||||
).all()
|
).all()
|
||||||
|
|
||||||
transactions = default_order(transactions, order=order)
|
transactions = default_order(transactions, order=order)
|
||||||
|
|||||||
Reference in New Issue
Block a user