-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add access level to user group memberships
- Loading branch information
Showing
5 changed files
with
127 additions
and
38 deletions.
There are no files selected for viewing
21 changes: 21 additions & 0 deletions
21
migrations/2024080611510000-add-user_group_memberships-access.js
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,21 @@ | ||
"use strict"; | ||
|
||
module.exports = { | ||
async up(queryInterface, Sequelize) { | ||
// set access to ReadWrite for all current user_group_memberships | ||
await queryInterface.sequelize.query( | ||
`ALTER TABLE user_group_memberships | ||
ADD access int(11) DEFAULT 3;` | ||
); | ||
await queryInterface.sequelize.query( | ||
`ALTER TABLE user_group_memberships | ||
MODIFY COLUMN access int(11) NOT NULL;` | ||
); | ||
}, | ||
async down(queryInterface, Sequelize) { | ||
await queryInterface.sequelize.query( | ||
`ALTER TABLE user_group_memberships | ||
DROP access;` | ||
); | ||
}, | ||
}; |
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
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