Implement scoping on be (#144)

This commit is contained in:
Charles Bochet
2023-05-26 14:00:32 +02:00
committed by GitHub
parent f79a45e7e6
commit 26d3716ae7
981 changed files with 14545 additions and 24213 deletions

View File

@ -8,6 +8,11 @@ datasource db {
url = env("SERVER_DATABASE_URL")
}
generator nestgraphql {
provider = "node node_modules/prisma-nestjs-graphql"
output = "../../src/api/@generated"
}
model User {
id String @id
createdAt DateTime @default(now())
@ -69,7 +74,10 @@ model Company {
accountOwnerId String?
accountOwner User? @relation(fields: [accountOwnerId], references: [id])
people Person[]
/// @TypeGraphQL.omit(input: true)
workspaceId String
/// @TypeGraphQL.omit(input: true)
workspace Workspace @relation(fields: [workspaceId], references: [id])
@@map("companies")
@ -87,7 +95,10 @@ model Person {
city String
companyId String?
company Company? @relation(fields: [companyId], references: [id])
/// @TypeGraphQL.omit(input: true)
workspaceId String
/// @TypeGraphQL.omit(input: true)
workspace Workspace @relation(fields: [workspaceId], references: [id])
@@map("people")