Skip to content

Commit

Permalink
fix : format schema + revert onUpdate
Browse files Browse the repository at this point in the history
  • Loading branch information
houssembaltii committed Aug 23, 2024
1 parent 0d9af0a commit 4539919
Showing 1 changed file with 9 additions and 11 deletions.
20 changes: 9 additions & 11 deletions prisma/schema.prisma
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ generator client {
}

datasource db {
provider = "postgresql"
url = env("DATABASE_URL")
provider = "postgresql"
url = env("DATABASE_URL")
}

model Account {
Expand All @@ -28,7 +28,7 @@ model Account {
created_at Int?
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
@@unique([provider, providerAccountId])
@@unique([provider, providerAccountId])
}

model Session {
Expand Down Expand Up @@ -59,9 +59,9 @@ model VerificationToken {
}

model ScopesOnIssues {
issue Issue @relation(fields: [issueId], references: [id], onUpdate:Restrict)
issue Issue @relation(fields: [issueId], references: [id], onUpdate: NoAction)
issueId String
scope Scope @relation(fields: [scopeId], references: [id], onUpdate: Restrict)
scope Scope @relation(fields: [scopeId], references: [id], onUpdate: NoAction)
scopeId String
@@id([issueId, scopeId])
Expand All @@ -77,9 +77,8 @@ model Scope {
updatedAt DateTime @updatedAt
issues ScopesOnIssues[]
@@index([name])
@@index([description])
@@index([name])
@@index([description])
}

model Issue {
Expand All @@ -90,9 +89,8 @@ model Issue {
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
@@index([title])
@@index([description])
@@index([title])
@@index([description])
}

enum Role {
Expand Down

0 comments on commit 4539919

Please sign in to comment.