3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-10 20:35:02 +00:00

Add case_id to mutes. Add !mutes command to list mutes.

This commit is contained in:
Dragory 2018-08-05 00:18:50 +03:00
parent 60c434999e
commit 7a372533ec
9 changed files with 131 additions and 3 deletions

View file

@ -0,0 +1,12 @@
exports.up = async function(knex, Promise) {
await knex.schema.table('mutes', table => {
table.integer('case_id').unsigned().nullable().defaultTo(null).after('user_id').references('id').inTable('cases').onDelete('SET NULL');
});
};
exports.down = async function(knex, Promise) {
await knex.schema.table('mutes', table => {
table.dropForeign('case_id');
table.dropColumn('case_id');
});
};