mirror of
https://github.com/eitchtee/WYGIWYH.git
synced 2026-03-24 18:31:26 +01:00
Merge pull request #218
fix(tools:currency-converter): currency list displaying oldest result instead of newest
This commit is contained in:
@@ -40,7 +40,7 @@ def get_currency_exchange_map(date=None) -> Dict[str, dict]:
|
||||
date_diff=Func(Extract(F("date") - Value(date), "epoch"), function="ABS"),
|
||||
effective_rate=F("rate"),
|
||||
)
|
||||
.order_by("from_currency", "to_currency", "date_diff")
|
||||
.order_by("from_currency", "to_currency", "-date_diff")
|
||||
.distinct()
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user