Skip to content

Commit

Permalink
add createdAt to groupInvite
Browse files Browse the repository at this point in the history
  • Loading branch information
owens1127 committed Nov 3, 2024
1 parent b9cfaba commit d5b4524
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ CREATE TABLE "GroupInvite" (
"intitiatorId" TEXT NOT NULL,
"email" TEXT NOT NULL,
"firstName" TEXT NOT NULL,
"lastName" TEXT NOT NULL
"lastName" TEXT NOT NULL,
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP
);

-- CreateTable
Expand Down
5 changes: 3 additions & 2 deletions packages/db/prisma/schema.prisma
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,9 @@ model GroupInvite {
email String
firstName String
lastName String
group Group @relation(fields: [groupId], references: [groupId], onDelete: Cascade)
intitiator User @relation(fields: [intitiatorId], references: [userId], onDelete: Cascade)
group Group @relation(fields: [groupId], references: [groupId], onDelete: Cascade)
intitiator User @relation(fields: [intitiatorId], references: [userId], onDelete: Cascade)
createdAt DateTime @default(now())
@@unique([groupId, email])
}

0 comments on commit d5b4524

Please sign in to comment.