-
-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🎉 feat: multiple Discord roles for permissions (#574)
- Loading branch information
Showing
13 changed files
with
318 additions
and
168 deletions.
There are no files selected for viewing
71 changes: 71 additions & 0 deletions
71
packages/api/prisma/migrations/20220403071829_/migration.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
-- CreateTable | ||
CREATE TABLE "_dispatchRoles" ( | ||
"A" TEXT NOT NULL, | ||
"B" TEXT NOT NULL | ||
); | ||
|
||
-- CreateTable | ||
CREATE TABLE "_leoSupervisorRoles" ( | ||
"A" TEXT NOT NULL, | ||
"B" TEXT NOT NULL | ||
); | ||
|
||
-- CreateTable | ||
CREATE TABLE "_taxiRoles" ( | ||
"A" TEXT NOT NULL, | ||
"B" TEXT NOT NULL | ||
); | ||
|
||
-- CreateTable | ||
CREATE TABLE "_towRoles" ( | ||
"A" TEXT NOT NULL, | ||
"B" TEXT NOT NULL | ||
); | ||
|
||
-- CreateIndex | ||
CREATE UNIQUE INDEX "_dispatchRoles_AB_unique" ON "_dispatchRoles"("A", "B"); | ||
|
||
-- CreateIndex | ||
CREATE INDEX "_dispatchRoles_B_index" ON "_dispatchRoles"("B"); | ||
|
||
-- CreateIndex | ||
CREATE UNIQUE INDEX "_leoSupervisorRoles_AB_unique" ON "_leoSupervisorRoles"("A", "B"); | ||
|
||
-- CreateIndex | ||
CREATE INDEX "_leoSupervisorRoles_B_index" ON "_leoSupervisorRoles"("B"); | ||
|
||
-- CreateIndex | ||
CREATE UNIQUE INDEX "_taxiRoles_AB_unique" ON "_taxiRoles"("A", "B"); | ||
|
||
-- CreateIndex | ||
CREATE INDEX "_taxiRoles_B_index" ON "_taxiRoles"("B"); | ||
|
||
-- CreateIndex | ||
CREATE UNIQUE INDEX "_towRoles_AB_unique" ON "_towRoles"("A", "B"); | ||
|
||
-- CreateIndex | ||
CREATE INDEX "_towRoles_B_index" ON "_towRoles"("B"); | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_dispatchRoles" ADD FOREIGN KEY ("A") REFERENCES "DiscordRole"("id") ON DELETE CASCADE ON UPDATE CASCADE; | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_dispatchRoles" ADD FOREIGN KEY ("B") REFERENCES "DiscordRoles"("id") ON DELETE CASCADE ON UPDATE CASCADE; | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_leoSupervisorRoles" ADD FOREIGN KEY ("A") REFERENCES "DiscordRole"("id") ON DELETE CASCADE ON UPDATE CASCADE; | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_leoSupervisorRoles" ADD FOREIGN KEY ("B") REFERENCES "DiscordRoles"("id") ON DELETE CASCADE ON UPDATE CASCADE; | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_taxiRoles" ADD FOREIGN KEY ("A") REFERENCES "DiscordRole"("id") ON DELETE CASCADE ON UPDATE CASCADE; | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_taxiRoles" ADD FOREIGN KEY ("B") REFERENCES "DiscordRoles"("id") ON DELETE CASCADE ON UPDATE CASCADE; | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_towRoles" ADD FOREIGN KEY ("A") REFERENCES "DiscordRole"("id") ON DELETE CASCADE ON UPDATE CASCADE; | ||
|
||
-- AddForeignKey | ||
ALTER TABLE "_towRoles" ADD FOREIGN KEY ("B") REFERENCES "DiscordRoles"("id") ON DELETE CASCADE ON UPDATE CASCADE; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.