paid for all, split evenly (#59)

This commit is contained in:
Mert Demir
2024-01-27 00:26:58 +09:00
committed by GitHub
parent 545cf75e99
commit 58ee685e22

View File

@@ -106,7 +106,11 @@ export function ExpenseForm({
expenseDate: new Date(),
amount: 0,
category: 0, // category with Id 0 is General
paidFor: [],
// paid for all, split evenly
paidFor: group.participants.map(({ id }) => ({
participant: id,
shares: 1,
})),
paidBy: getSelectedPayer(),
isReimbursement: false,
splitMode: 'EVENLY',