Fix migrations

This commit is contained in:
Charles Bochet
2023-07-26 02:59:14 -07:00
parent f6faff407a
commit 574d23084e
2 changed files with 3 additions and 3 deletions

View File

@ -5,7 +5,7 @@
*/
-- AlterTable
ALTER TABLE "comment_thread_targets" ADD COLUMN "workspaceId" TEXT NOT NULL;
ALTER TABLE "comment_thread_targets" ADD COLUMN "workspaceId" TEXT;
-- AddForeignKey
ALTER TABLE "comment_thread_targets" ADD CONSTRAINT "comment_thread_targets_workspaceId_fkey" FOREIGN KEY ("workspaceId") REFERENCES "workspaces"("id") ON DELETE RESTRICT ON UPDATE CASCADE;

View File

@ -384,9 +384,9 @@ model CommentThreadTarget {
commentThread CommentThread @relation(fields: [commentThreadId], references: [id], onDelete: Cascade)
commentThreadId String
/// @TypeGraphQL.omit(input: true, output: false)
workspace Workspace @relation(fields: [workspaceId], references: [id])
workspace Workspace? @relation(fields: [workspaceId], references: [id])
/// @TypeGraphQL.omit(input: true, output: true)
workspaceId String
workspaceId String?
commentableType CommentableType
commentableId String