diff --git a/frontend/apps/web/src/pages/transactions/TransactionDetail/purchase/TransactionPositions.tsx b/frontend/apps/web/src/pages/transactions/TransactionDetail/purchase/TransactionPositions.tsx index d3ab6fd..f9b4095 100644 --- a/frontend/apps/web/src/pages/transactions/TransactionDetail/purchase/TransactionPositions.tsx +++ b/frontend/apps/web/src/pages/transactions/TransactionDetail/purchase/TransactionPositions.tsx @@ -92,10 +92,11 @@ export const TransactionPositions: React.FC = ({ ) ); } + const accs = accountIDsToShow.map((id) => accountIDMap[id]).sort(getAccountSortFunc("name")); return { - shownAccounts: accountIDsToShow.map((id) => accountIDMap[id]).sort(getAccountSortFunc("name")), - shownAccountIDs: accountIDsToShow, + shownAccounts: accs, + shownAccountIDs: accs.map((a) => a.id), }; }, [transaction, positions, additionalPurchaseItemAccounts, accountIDMap]);