diff --git a/apps/api/src/app/order/order.service.ts b/apps/api/src/app/order/order.service.ts index a1fa4db6c..0255a5011 100644 --- a/apps/api/src/app/order/order.service.ts +++ b/apps/api/src/app/order/order.service.ts @@ -291,7 +291,8 @@ export class OrderService { withExcludedAccounts?: boolean; }): Promise { let orderBy: Prisma.Enumerable = [ - { date: 'asc' } + { date: 'asc' }, + { id: 'asc' } ]; const where: Prisma.OrderWhereInput = { userId }; @@ -367,7 +368,7 @@ export class OrderService { } if (sortColumn) { - orderBy = [{ [sortColumn]: sortDirection }]; + orderBy = [{ [sortColumn]: sortDirection }, { id: sortDirection }]; } if (types) {