Built motion from commit c49361c37b5f784889c8087ac6e0e91b7e6b561a. Version 3.0.0...
[motion-next.git] / server / migrations / 2.2.0.js
index 05edaa8..e7ae0f2 100644 (file)
@@ -1 +1 @@
-const a965_0x12e8=['queryInterface','../config/logger','enqueue','type','join','renameColumn','then','info','table\x20dropped\x20%s','csc','skebby','prototype','Changed\x20column\x20%s\x20in\x20table\x20%s','infobip','query','Added\x20column\x20%s\x20to\x20%s','inspect','addColumn','clickatell','plivo','sequence','catch','util','connectel','ENUM','stringify','removeIndex\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','changeColumn','clicksend','intelepeer','removeColumn','dropTable','phoneBarListenPort','users','sequelize','tail','finally','final','Removed\x20column\x20%s\x20from\x20%s','addIndex','INTEGER','migration'];(function(_0x555209,_0x12e83f){const _0x16b719=function(_0x146d45){while(--_0x146d45){_0x555209['push'](_0x555209['shift']());}};_0x16b719(++_0x12e83f);}(a965_0x12e8,0x190));const a965_0x16b7=function(_0x555209,_0x12e83f){_0x555209=_0x555209-0x0;let _0x16b719=a965_0x12e8[_0x555209];return _0x16b719;};const _0x4d47f6=a965_0x16b7;'use strict';const util=require(_0x4d47f6('0x9')),logger=require(_0x4d47f6('0x1f'))(_0x4d47f6('0x1d')),Sequence=function(){};Sequence[_0x4d47f6('0x29')]['enqueue']=function(_0x146d45){const _0x15a211=_0x4d47f6;this['tail']=this['tail']?this[_0x15a211('0x17')][_0x15a211('0x18')](_0x146d45):_0x146d45();};const Migration=function(_0x40f045){const _0x3d4252=_0x4d47f6;this[_0x3d4252('0x1e')]=_0x40f045,this[_0x3d4252('0x7')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x49d799,_0x217798,_0x1512cc){const _0x4a23a2=_0x4d47f6,_0x3eff17=this;this[_0x4a23a2('0x7')][_0x4a23a2('0x20')](function(){const _0x3dba7a=_0x4a23a2;return _0x3eff17[_0x3dba7a('0x1e')]['changeColumn'](_0x49d799,_0x217798,_0x1512cc)[_0x3dba7a('0x24')](function(){const _0x17d738=_0x3dba7a;logger[_0x17d738('0x25')](_0x17d738('0x2a'),_0x217798,_0x49d799);})['catch'](function(_0x4823a7){const _0x8df44a=_0x3dba7a;logger['info'](JSON[_0x8df44a('0xc')](_0x4823a7));});});},Migration['prototype'][_0x4d47f6('0x4')]=function(_0x4db83d,_0x298198,_0x3a2f84){const _0x37f216=_0x4d47f6,_0x2c04ec=this;this['sequence'][_0x37f216('0x20')](function(){const _0x3b66a7=_0x37f216;return _0x2c04ec[_0x3b66a7('0x1e')][_0x3b66a7('0x4')](_0x4db83d,_0x298198,_0x3a2f84)['then'](function(){const _0x254f73=_0x3b66a7;logger[_0x254f73('0x25')](_0x254f73('0x2'),_0x298198,_0x4db83d);})[_0x3b66a7('0x8')](function(_0x5074f4){const _0x403d58=_0x3b66a7;logger[_0x403d58('0x25')](JSON[_0x403d58('0xc')](_0x5074f4));});});},Migration[_0x4d47f6('0x29')][_0x4d47f6('0x13')]=function(_0x4d7a94){const _0x4842f6=_0x4d47f6,_0x4e3973=this;this[_0x4842f6('0x7')][_0x4842f6('0x20')](function(){const _0x598510=_0x4842f6;return _0x4e3973['queryInterface'][_0x598510('0x13')](_0x4d7a94,{'force':!![]})[_0x598510('0x24')](function(){const _0x33acc1=_0x598510;logger['info'](_0x33acc1('0x26'),_0x4d7a94);})[_0x598510('0x8')](function(_0x2b957c){const _0x961bde=_0x598510;logger[_0x961bde('0x25')](JSON[_0x961bde('0xc')](_0x2b957c));});});},Migration['prototype'][_0x4d47f6('0x1b')]=function(_0x37d161,_0x150c7f,_0x11b7c9){const _0x31effa=_0x4d47f6,_0x4c32ef=this;this[_0x31effa('0x7')][_0x31effa('0x20')](function(){const _0x5aa88d=_0x31effa;return _0x4c32ef[_0x5aa88d('0x1e')][_0x5aa88d('0x1b')](_0x37d161,_0x150c7f,{'indexName':_0x11b7c9})['then'](function(){const _0x138943=_0x5aa88d;logger[_0x138943('0x25')]('addIndex\x20%s\x20%s\x20%s',_0x37d161,_0x150c7f[_0x138943('0x22')](','),_0x11b7c9);})['catch'](function(_0x32134a){const _0x194568=_0x5aa88d;logger['info'](JSON[_0x194568('0xc')](_0x32134a));});});},Migration[_0x4d47f6('0x29')]['removeIndex']=function(_0x47acf2,_0x10de84){const _0x1b00e7=_0x4d47f6,_0x5b1eb5=this;this[_0x1b00e7('0x7')][_0x1b00e7('0x20')](function(){const _0x103041=_0x1b00e7;return _0x5b1eb5[_0x103041('0x1e')]['removeIndex'](_0x47acf2,_0x10de84)[_0x103041('0x24')](function(){const _0x21e0af=_0x103041;logger['info'](_0x21e0af('0xd'),_0x47acf2,_0x10de84);})['catch'](function(_0xf57e7d){const _0x1455ed=_0x103041;logger[_0x1455ed('0x25')](JSON[_0x1455ed('0xc')](_0xf57e7d));});});},Migration[_0x4d47f6('0x29')]['query']=function(_0x392ca8){const _0x34ecc0=_0x4d47f6,_0x12e2df=this;this['sequence'][_0x34ecc0('0x20')](function(){const _0x1545b3=_0x34ecc0;return _0x12e2df[_0x1545b3('0x1e')][_0x1545b3('0x16')][_0x1545b3('0x1')](_0x392ca8)[_0x1545b3('0x24')](function(){logger['info']('query\x20%s',_0x392ca8);})[_0x1545b3('0x8')](function(_0x4fd082){const _0x354857=_0x1545b3;logger[_0x354857('0x25')](JSON[_0x354857('0xc')](_0x4fd082));});});},Migration[_0x4d47f6('0x29')][_0x4d47f6('0x12')]=function(_0x38e022,_0x2e36ed){const _0x1cae28=_0x4d47f6,_0x259e26=this;this['sequence'][_0x1cae28('0x20')](function(){const _0x2be0db=_0x1cae28;return _0x259e26[_0x2be0db('0x1e')]['removeColumn'](_0x38e022,_0x2e36ed)['then'](function(){const _0x5662cb=_0x2be0db;logger[_0x5662cb('0x25')](_0x5662cb('0x1a'),_0x2e36ed,_0x38e022);})['catch'](function(_0x2346a7){const _0x2f34fb=_0x2be0db;logger[_0x2f34fb('0x25')](util[_0x2f34fb('0x3')](_0x2346a7,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x4d47f6('0x23')]=function(_0x47fe64,_0x2dbf58,_0x47e406){const _0x2d7d12=_0x4d47f6,_0x1dd598=this;this[_0x2d7d12('0x7')][_0x2d7d12('0x20')](function(){const _0x1104aa=_0x2d7d12;return _0x1dd598[_0x1104aa('0x1e')]['renameColumn'](_0x47fe64,_0x2dbf58,_0x47e406)['then'](function(){const _0x46dac7=_0x1104aa;logger['info'](_0x46dac7('0xe'),_0x2dbf58,_0x47e406,_0x47fe64);})[_0x1104aa('0x8')](function(_0x56009e){const _0x9297d2=_0x1104aa;logger['info'](util[_0x9297d2('0x3')](_0x56009e,{'showHidden':![],'depth':null}));});});},Migration[_0x4d47f6('0x29')][_0x4d47f6('0x19')]=function(_0x431b49){const _0x2cd6e9=_0x4d47f6;this[_0x2cd6e9('0x7')][_0x2cd6e9('0x20')](function(){return _0x431b49();});},module['exports']={'up':function(_0x2c5661,_0x476ff3){return new Promise(function(_0x1f5666){const _0x174bb9=a965_0x16b7,_0x38365e=new Migration(_0x2c5661);_0x38365e[_0x174bb9('0xf')]('sms_accounts',_0x174bb9('0x21'),{'type':_0x476ff3[_0x174bb9('0xb')]('twilio',_0x174bb9('0x28'),_0x174bb9('0xa'),_0x174bb9('0x10'),_0x174bb9('0x6'),_0x174bb9('0x5'),_0x174bb9('0x27'),_0x174bb9('0x0'),_0x174bb9('0x11'))}),_0x38365e[_0x174bb9('0xf')](_0x174bb9('0x15'),_0x174bb9('0x14'),{'type':_0x476ff3[_0x174bb9('0x1c')](0x5),'defaultValue':0x1428}),_0x38365e[_0x174bb9('0x19')](_0x1f5666);});},'down':function(){}};
\ No newline at end of file
+const a965_0x12d4=['removeColumn','INTEGER','removeIndex\x20%s\x20%s','removeIndex','sequence','table\x20dropped\x20%s','query','util','sms_accounts','users','queryInterface','info','infobip','clicksend','sequelize','join','twilio','addColumn','Added\x20column\x20%s\x20to\x20%s','connectel','intelepeer','then','ENUM','renameColumn','final','csc','../config/logger','stringify','addIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','exports','dropTable','plivo','clickatell','enqueue','changeColumn','inspect','catch','finally','prototype','tail','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','skebby'];(function(_0x2e8f15,_0x12d4cc){const _0x4e92b8=function(_0x21d3a5){while(--_0x21d3a5){_0x2e8f15['push'](_0x2e8f15['shift']());}};_0x4e92b8(++_0x12d4cc);}(a965_0x12d4,0x161));const a965_0x4e92=function(_0x2e8f15,_0x12d4cc){_0x2e8f15=_0x2e8f15-0x0;let _0x4e92b8=a965_0x12d4[_0x2e8f15];return _0x4e92b8;};const _0x46e325=a965_0x4e92;'use strict';const util=require(_0x46e325('0x29')),logger=require(_0x46e325('0x11'))('migration'),Sequence=function(){};Sequence[_0x46e325('0x1e')][_0x46e325('0x19')]=function(_0x21d3a5){const _0x3cc576=_0x46e325;this[_0x3cc576('0x1f')]=this[_0x3cc576('0x1f')]?this[_0x3cc576('0x1f')][_0x3cc576('0x1d')](_0x21d3a5):_0x21d3a5();};const Migration=function(_0x5b9d8d){const _0x3b69ef=_0x46e325;this['queryInterface']=_0x5b9d8d,this[_0x3b69ef('0x26')]=new Sequence();};Migration[_0x46e325('0x1e')][_0x46e325('0x1a')]=function(_0x15f02e,_0x1d36a0,_0x45592e){const _0x238389=_0x46e325,_0x48805b=this;this[_0x238389('0x26')][_0x238389('0x19')](function(){const _0x4f1a68=_0x238389;return _0x48805b[_0x4f1a68('0x1')][_0x4f1a68('0x1a')](_0x15f02e,_0x1d36a0,_0x45592e)['then'](function(){const _0x2b1093=_0x4f1a68;logger[_0x2b1093('0x2')](_0x2b1093('0x14'),_0x1d36a0,_0x15f02e);})[_0x4f1a68('0x1c')](function(_0x6a3aeb){const _0x36879b=_0x4f1a68;logger[_0x36879b('0x2')](JSON['stringify'](_0x6a3aeb));});});},Migration[_0x46e325('0x1e')][_0x46e325('0x8')]=function(_0x202d01,_0x4dd5c9,_0x12c564){const _0x4d1231=_0x46e325,_0x20d7e2=this;this[_0x4d1231('0x26')][_0x4d1231('0x19')](function(){const _0x4c251d=_0x4d1231;return _0x20d7e2[_0x4c251d('0x1')][_0x4c251d('0x8')](_0x202d01,_0x4dd5c9,_0x12c564)[_0x4c251d('0xc')](function(){const _0x54f663=_0x4c251d;logger[_0x54f663('0x2')](_0x54f663('0x9'),_0x4dd5c9,_0x202d01);})[_0x4c251d('0x1c')](function(_0x28a4c9){const _0x5c423f=_0x4c251d;logger[_0x5c423f('0x2')](JSON[_0x5c423f('0x12')](_0x28a4c9));});});},Migration[_0x46e325('0x1e')][_0x46e325('0x16')]=function(_0x2014c){const _0x5cd520=_0x46e325,_0x3e6282=this;this[_0x5cd520('0x26')][_0x5cd520('0x19')](function(){const _0x4d7ac0=_0x5cd520;return _0x3e6282[_0x4d7ac0('0x1')][_0x4d7ac0('0x16')](_0x2014c,{'force':!![]})[_0x4d7ac0('0xc')](function(){const _0x131fd6=_0x4d7ac0;logger['info'](_0x131fd6('0x27'),_0x2014c);})[_0x4d7ac0('0x1c')](function(_0x4def6f){const _0x35e26c=_0x4d7ac0;logger[_0x35e26c('0x2')](JSON[_0x35e26c('0x12')](_0x4def6f));});});},Migration[_0x46e325('0x1e')][_0x46e325('0x13')]=function(_0x48969e,_0x2792ac,_0x11d285){const _0x27e34d=_0x46e325,_0x9068da=this;this[_0x27e34d('0x26')]['enqueue'](function(){const _0x15b757=_0x27e34d;return _0x9068da['queryInterface'][_0x15b757('0x13')](_0x48969e,_0x2792ac,{'indexName':_0x11d285})['then'](function(){const _0x36bc08=_0x15b757;logger[_0x36bc08('0x2')]('addIndex\x20%s\x20%s\x20%s',_0x48969e,_0x2792ac[_0x36bc08('0x6')](','),_0x11d285);})[_0x15b757('0x1c')](function(_0x2e3db3){const _0x4a3e55=_0x15b757;logger[_0x4a3e55('0x2')](JSON[_0x4a3e55('0x12')](_0x2e3db3));});});},Migration[_0x46e325('0x1e')][_0x46e325('0x25')]=function(_0x4ed431,_0x216201){const _0x38ea81=_0x46e325,_0xf775f7=this;this[_0x38ea81('0x26')]['enqueue'](function(){const _0x33642f=_0x38ea81;return _0xf775f7[_0x33642f('0x1')][_0x33642f('0x25')](_0x4ed431,_0x216201)[_0x33642f('0xc')](function(){const _0x5848c0=_0x33642f;logger['info'](_0x5848c0('0x24'),_0x4ed431,_0x216201);})[_0x33642f('0x1c')](function(_0x8e5c89){logger['info'](JSON['stringify'](_0x8e5c89));});});},Migration[_0x46e325('0x1e')][_0x46e325('0x28')]=function(_0x1db797){const _0x12d802=_0x46e325,_0xe7be66=this;this[_0x12d802('0x26')][_0x12d802('0x19')](function(){const _0x5c0856=_0x12d802;return _0xe7be66[_0x5c0856('0x1')][_0x5c0856('0x5')]['query'](_0x1db797)[_0x5c0856('0xc')](function(){const _0x4a53a6=_0x5c0856;logger[_0x4a53a6('0x2')]('query\x20%s',_0x1db797);})['catch'](function(_0x1ad656){logger['info'](JSON['stringify'](_0x1ad656));});});},Migration[_0x46e325('0x1e')][_0x46e325('0x22')]=function(_0x1bf8b0,_0x4f68f9){const _0x3743b8=_0x46e325,_0x4f54f8=this;this[_0x3743b8('0x26')][_0x3743b8('0x19')](function(){const _0x2fa148=_0x3743b8;return _0x4f54f8['queryInterface'][_0x2fa148('0x22')](_0x1bf8b0,_0x4f68f9)[_0x2fa148('0xc')](function(){const _0x348a88=_0x2fa148;logger[_0x348a88('0x2')]('Removed\x20column\x20%s\x20from\x20%s',_0x4f68f9,_0x1bf8b0);})[_0x2fa148('0x1c')](function(_0x51f277){const _0x4011d4=_0x2fa148;logger['info'](util[_0x4011d4('0x1b')](_0x51f277,{'showHidden':![],'depth':null}));});});},Migration[_0x46e325('0x1e')][_0x46e325('0xe')]=function(_0x5dd343,_0x316e2c,_0x210842){const _0x4b62e8=_0x46e325,_0x3df069=this;this['sequence'][_0x4b62e8('0x19')](function(){const _0x424d27=_0x4b62e8;return _0x3df069[_0x424d27('0x1')][_0x424d27('0xe')](_0x5dd343,_0x316e2c,_0x210842)[_0x424d27('0xc')](function(){const _0xafe110=_0x424d27;logger[_0xafe110('0x2')](_0xafe110('0x20'),_0x316e2c,_0x210842,_0x5dd343);})[_0x424d27('0x1c')](function(_0x5f30b4){const _0x3229b9=_0x424d27;logger[_0x3229b9('0x2')](util['inspect'](_0x5f30b4,{'showHidden':![],'depth':null}));});});},Migration[_0x46e325('0x1e')]['final']=function(_0x4af906){const _0x1d0d2c=_0x46e325;this['sequence'][_0x1d0d2c('0x19')](function(){return _0x4af906();});},module[_0x46e325('0x15')]={'up':function(_0x195bd7,_0x5c48bf){return new Promise(function(_0x5e1c04){const _0x207928=a965_0x4e92,_0x4b1abf=new Migration(_0x195bd7);_0x4b1abf['changeColumn'](_0x207928('0x2a'),'type',{'type':_0x5c48bf[_0x207928('0xd')](_0x207928('0x7'),_0x207928('0x21'),_0x207928('0xa'),_0x207928('0x4'),_0x207928('0x17'),_0x207928('0x18'),_0x207928('0x10'),_0x207928('0x3'),_0x207928('0xb'))}),_0x4b1abf[_0x207928('0x1a')](_0x207928('0x0'),'phoneBarListenPort',{'type':_0x5c48bf[_0x207928('0x23')](0x5),'defaultValue':0x1428}),_0x4b1abf[_0x207928('0xf')](_0x5e1c04);});},'down':function(){}};
\ No newline at end of file