add migrations for new table, columns and modified column names

This commit is contained in:
Bilal Catic
2019-06-09 11:36:34 +02:00
parent 0a712bf501
commit c021b55c26
4 changed files with 103 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
'use strict';
module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.addColumn('doorLockEvents', 'resourceId', {
type: Sequelize.TEXT,
after: 'memberId',
});
},
down: (queryInterface, Sequelize) => {
return queryInterface.removeColumn('doorLockEvents', 'resourceId');
}
};