spee.ch/migrations/Add-UserId-To-Certificate.js
2017-09-19 18:50:25 -07:00

20 lines
430 B
JavaScript

module.exports = {
up: (queryInterface, Sequelize) => {
// logic for transforming into the new state
queryInterface.addColumn(
'Certificate',
'UserId',
{
type : Sequelize.STRING,
allowNull: true,
}
);
},
down: (queryInterface, Sequelize) => {
// logic for reverting the changes
queryInterface.removeColumn(
'Certificate',
'UserId'
);
},
};