Order by descending id to get the last 10 purchases

Closes #12497
(grafted from f71e3a79e0c9249616a59ef2f96e807b12af3a44)

--HG--
branch : 6.0
This commit is contained in:
Cédric Krier committed 2023-08-17 16:18:21 +02:00
1 parent 3bff7a703f
commit 5a57867a0c
1 file changed
+1 -1
+1 -1
View File
@@ -442,7 +442,7 @@ class Purchase(
table.invoice_method,
where=(table.party == self.party.id)
& (table.invoice_party == invoice_party),
order_by=table.id,
order_by=table.id.desc,
limit=10)
cursor.execute(*subquery.select(
subquery.currency,