X-Git-Url: http://repos.xcallymotion.com/?a=blobdiff_plain;f=server%2Fmigrations%2F20160407163943-trunks.js;h=c88d75146bc10bc7dfa874a8b0600aaa45a545d9;hb=9c67eff8b98f3784e4fa1b031a29d4590547e055;hp=b929d55550c2cda9ffb4bc01773219c2a211aac9;hpb=2c028dc81dced7b7435dd16e21e89e4178a6b18c;p=motion.git diff --git a/server/migrations/20160407163943-trunks.js b/server/migrations/20160407163943-trunks.js index b929d55..c88d751 100644 --- a/server/migrations/20160407163943-trunks.js +++ b/server/migrations/20160407163943-trunks.js @@ -1 +1,37 @@ -var _0x9f77=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x65\x78\x70\x6F\x72\x74\x73","\x74\x6F\x6F\x6C\x73\x5F\x74\x72\x75\x6E\x6B\x73","\x63\x6F\x6E\x74\x65\x78\x74","\x53\x54\x52\x49\x4E\x47","\x66\x72\x6F\x6D\x2D\x76\x6F\x69\x70\x2D\x70\x72\x6F\x76\x69\x64\x65\x72","\x63\x68\x61\x6E\x67\x65\x43\x6F\x6C\x75\x6D\x6E","\x66\x72\x6F\x6D\x2D\x73\x69\x70"];_0x9f77[0];module[_0x9f77[1]]= {up:function(_0x8747x1,_0x8747x2){_0x8747x1[_0x9f77[6]](_0x9f77[2],_0x9f77[3],{type:_0x8747x2[_0x9f77[4]],defaultValue:_0x9f77[5]})},down:function(_0x8747x1,_0x8747x2){_0x8747x1[_0x9f77[6]](_0x9f77[2],_0x9f77[3],{type:_0x8747x2[_0x9f77[4]],defaultValue:_0x9f77[7]})}} \ No newline at end of file +'use strict'; + +module.exports = { + up: function(queryInterface, Sequelize) { + /* + Add altering commands here. + Return a promise to correctly handle asynchronicity. + + Example: + return queryInterface.createTable('users', { id: Sequelize.INTEGER }); + */ + queryInterface.changeColumn( + 'tools_trunks', + 'context', { + type: Sequelize.STRING, + defaultValue: 'from-voip-provider' + } + ); + }, + + down: function(queryInterface, Sequelize) { + /* + Add reverting commands here. + Return a promise to correctly handle asynchronicity. + + Example: + return queryInterface.dropTable('users'); + */ + queryInterface.changeColumn( + 'tools_trunks', + 'context', { + type: Sequelize.STRING, + defaultValue: 'from-sip' + } + ); + } +};