fix(backend): add missing domain foreign keys
Some checks failed
deploy-socialize / image (push) Failing after 44s
deploy-socialize / deploy (push) Has been skipped

This commit is contained in:
2026-05-07 15:48:12 -04:00
parent e9fb1c5ee0
commit 49e2ca1774
14 changed files with 3109 additions and 26 deletions

View File

@@ -41,6 +41,10 @@ internal static class WorkspaceModelConfiguration
.HasDefaultValueSql("CURRENT_TIMESTAMP");
workspaceInvite.HasIndex(x => x.WorkspaceId);
workspaceInvite.HasIndex(x => new { x.WorkspaceId, x.Email, x.Status });
workspaceInvite.HasOne<Workspace>()
.WithMany()
.HasForeignKey(x => x.WorkspaceId)
.OnDelete(DeleteBehavior.Restrict);
});
return modelBuilder;