diff --git a/src/lib/actions/generateSampleData.ts b/src/lib/actions/generateSampleData.ts index 8b16d17..37cc53d 100644 --- a/src/lib/actions/generateSampleData.ts +++ b/src/lib/actions/generateSampleData.ts @@ -136,6 +136,9 @@ export default async function generateSampleData(): Promise { date.setDate(1); date.setMonth(date.getMonth() - i); + const categoryId = + categories.find((it) => it.name === 'Salary')?.id!; + await prisma.payment.create({ data: { userId: user.sub, @@ -143,7 +146,7 @@ export default async function generateSampleData(): Promise { date: date, payorId: entities[1].id, payeeId: entities[0].id, - categoryId: 5, + categoryId: categoryId, createdAt: date, updatedAt: date, },