Track HiveGrid Cloud planning reference

This commit is contained in:
david committed 2026-06-26 20:48:01 +02:00
1 parent b3d5ea6764
commit e341c5938a
5784 files changed
+1104929 -3

No files matched your search

@@ -0,0 +1,11 @@
-- Tenant-owned workspace roles. Existing default roles remain global with tenantId NULL.
ALTER TABLE "Role" ADD COLUMN "tenantId" TEXT;
ALTER TABLE "Role" ADD CONSTRAINT "Role_tenantId_fkey" FOREIGN KEY ("tenantId") REFERENCES "Tenant"("id") ON DELETE CASCADE ON UPDATE CASCADE;
CREATE INDEX "Role_tenantId_type_idx" ON "Role"("tenantId", "type");
DROP INDEX IF EXISTS "Role_name_key";
CREATE UNIQUE INDEX "Role_tenantId_name_key" ON "Role"("tenantId", "name");
CREATE UNIQUE INDEX "Role_global_name_key" ON "Role"("name") WHERE "tenantId" IS NULL;