aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/expense-form.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/expense-form.tsx')
-rw-r--r--src/components/expense-form.tsx6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/components/expense-form.tsx b/src/components/expense-form.tsx
index 035d22c..92e24d0 100644
--- a/src/components/expense-form.tsx
+++ b/src/components/expense-form.tsx
@@ -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',