Built motion from commit b517aaa2a6638133380e4d135c64a80893061362. Version 3.0.0...
[motion-next.git] / server / migrations / 2.4.15.js
1 const a998_0x1a49=['then','changeColumn','final','tail','UPDATE\x20sms_accounts\x20SET\x20baseUrl\x20=\x20\x22https://sms.csc.lv\x22\x20WHERE\x20type\x20=\x20\x22csc\x22','Added\x20column\x20%s\x20to\x20%s','Removed\x20column\x20%s\x20from\x20%s','exports','removeColumn','info','queryInterface','prototype','renameColumn','table\x20dropped\x20%s','migration','sequelize','indicesType','removeIndex','inspect','sequence','enqueue','indexName','finally','stringify','query','Changed\x20column\x20%s\x20in\x20table\x20%s','removeIndex\x20%s\x20%s','addIndex\x20%s\x20%s\x20%s\x20[%s]','dropTable','catch'];(function(_0x5a548f,_0x1a49c5){const _0x45aafc=function(_0x467deb){while(--_0x467deb){_0x5a548f['push'](_0x5a548f['shift']());}};_0x45aafc(++_0x1a49c5);}(a998_0x1a49,0x1d6));const a998_0x45aa=function(_0x5a548f,_0x1a49c5){_0x5a548f=_0x5a548f-0x0;let _0x45aafc=a998_0x1a49[_0x5a548f];return _0x45aafc;};const _0x12d782=a998_0x45aa;'use strict';const util=require('util'),logger=require('../config/logger')(_0x12d782('0x18')),Sequence=function(){};Sequence[_0x12d782('0x15')][_0x12d782('0x0')]=function(_0x467deb){const _0x5eb3d7=_0x12d782;this[_0x5eb3d7('0xd')]=this[_0x5eb3d7('0xd')]?this[_0x5eb3d7('0xd')][_0x5eb3d7('0x2')](_0x467deb):_0x467deb();};const Migration=function(_0x3ab53d){const _0x5e855e=_0x12d782;this[_0x5e855e('0x14')]=_0x3ab53d,this[_0x5e855e('0x1d')]=new Sequence();};Migration[_0x12d782('0x15')][_0x12d782('0xb')]=function(_0x21e77b,_0x1959d6,_0x3dcb82){const _0xb1bf6=_0x12d782,_0x5eb9aa=this;this['sequence'][_0xb1bf6('0x0')](function(){const _0x12531a=_0xb1bf6;return _0x5eb9aa[_0x12531a('0x14')]['changeColumn'](_0x21e77b,_0x1959d6,_0x3dcb82)[_0x12531a('0xa')](function(){const _0x38c378=_0x12531a;logger[_0x38c378('0x13')](_0x38c378('0x5'),_0x1959d6,_0x21e77b);})['catch'](function(_0x473f35){const _0x53213a=_0x12531a;logger[_0x53213a('0x13')](JSON[_0x53213a('0x3')](_0x473f35));});});},Migration[_0x12d782('0x15')]['addColumn']=function(_0x25fb51,_0x1d79b6,_0x2e62ed){const _0x261ba3=_0x12d782,_0xce213=this;this[_0x261ba3('0x1d')]['enqueue'](function(){const _0x1bfc9a=_0x261ba3;return _0xce213[_0x1bfc9a('0x14')]['addColumn'](_0x25fb51,_0x1d79b6,_0x2e62ed)[_0x1bfc9a('0xa')](function(){const _0x45fa08=_0x1bfc9a;logger[_0x45fa08('0x13')](_0x45fa08('0xf'),_0x1d79b6,_0x25fb51);})[_0x1bfc9a('0x9')](function(_0x42b8ed){const _0x301f8c=_0x1bfc9a;logger[_0x301f8c('0x13')](JSON[_0x301f8c('0x3')](_0x42b8ed));});});},Migration[_0x12d782('0x15')][_0x12d782('0x8')]=function(_0x67857c){const _0x2ba8fa=_0x12d782,_0x379618=this;this[_0x2ba8fa('0x1d')][_0x2ba8fa('0x0')](function(){const _0x49c2a1=_0x2ba8fa;return _0x379618['queryInterface']['dropTable'](_0x67857c,{'force':!![]})[_0x49c2a1('0xa')](function(){const _0x1f69b4=_0x49c2a1;logger['info'](_0x1f69b4('0x17'),_0x67857c);})[_0x49c2a1('0x9')](function(_0x29ba81){const _0x41cc36=_0x49c2a1;logger[_0x41cc36('0x13')](JSON['stringify'](_0x29ba81));});});},Migration[_0x12d782('0x15')]['addIndex']=function(_0x367bc2,_0x301f57,_0xfb23aa){const _0x131cac=_0x12d782,_0x22d1de=this;this[_0x131cac('0x1d')]['enqueue'](function(){const _0x126ae7=_0x131cac;return _0x22d1de[_0x126ae7('0x14')]['addIndex'](_0x367bc2,_0x301f57,{'indexName':_0xfb23aa[_0x126ae7('0x1')],'indicesType':_0xfb23aa[_0x126ae7('0x1a')]})[_0x126ae7('0xa')](function(){const _0x596f4c=_0x126ae7;logger['info'](_0x596f4c('0x7'),_0x367bc2,_0x301f57['join'](','),_0xfb23aa[_0x596f4c('0x1')],_0xfb23aa[_0x596f4c('0x1a')]);})[_0x126ae7('0x9')](function(_0x17a46f){const _0xe8d86e=_0x126ae7;logger[_0xe8d86e('0x13')](JSON[_0xe8d86e('0x3')](_0x17a46f));});});},Migration[_0x12d782('0x15')][_0x12d782('0x1b')]=function(_0xe45bf5,_0x1d95ea){const _0x6adc12=_0x12d782,_0xf2d9fb=this;this[_0x6adc12('0x1d')][_0x6adc12('0x0')](function(){const _0x4f36a8=_0x6adc12;return _0xf2d9fb[_0x4f36a8('0x14')][_0x4f36a8('0x1b')](_0xe45bf5,_0x1d95ea)[_0x4f36a8('0xa')](function(){const _0x2b0743=_0x4f36a8;logger[_0x2b0743('0x13')](_0x2b0743('0x6'),_0xe45bf5,_0x1d95ea);})[_0x4f36a8('0x9')](function(_0x87232){const _0x2590d9=_0x4f36a8;logger[_0x2590d9('0x13')](JSON[_0x2590d9('0x3')](_0x87232));});});},Migration['prototype'][_0x12d782('0x4')]=function(_0x25368f){const _0x11bf25=_0x12d782,_0x2320df=this;this['sequence'][_0x11bf25('0x0')](function(){const _0x4c4630=_0x11bf25;return _0x2320df[_0x4c4630('0x14')][_0x4c4630('0x19')][_0x4c4630('0x4')](_0x25368f)[_0x4c4630('0xa')](function(){const _0x55cf52=_0x4c4630;logger[_0x55cf52('0x13')]('query\x20%s',_0x25368f);})[_0x4c4630('0x9')](function(_0x16a6a8){const _0x268513=_0x4c4630;logger[_0x268513('0x13')](JSON[_0x268513('0x3')](_0x16a6a8));});});},Migration[_0x12d782('0x15')][_0x12d782('0x12')]=function(_0x454ca2,_0x26f432){const _0x1fe2d8=_0x12d782,_0x1fcc8e=this;this[_0x1fe2d8('0x1d')][_0x1fe2d8('0x0')](function(){const _0x57af73=_0x1fe2d8;return _0x1fcc8e[_0x57af73('0x14')]['removeColumn'](_0x454ca2,_0x26f432)[_0x57af73('0xa')](function(){const _0x38d3a0=_0x57af73;logger[_0x38d3a0('0x13')](_0x38d3a0('0x10'),_0x26f432,_0x454ca2);})[_0x57af73('0x9')](function(_0x32335b){const _0x1186d8=_0x57af73;logger[_0x1186d8('0x13')](util['inspect'](_0x32335b,{'showHidden':![],'depth':null}));});});},Migration[_0x12d782('0x15')][_0x12d782('0x16')]=function(_0x536caf,_0x3c63b9,_0x5dd92c){const _0x3b51c8=_0x12d782,_0x199d3b=this;this[_0x3b51c8('0x1d')]['enqueue'](function(){const _0x12068b=_0x3b51c8;return _0x199d3b[_0x12068b('0x14')]['renameColumn'](_0x536caf,_0x3c63b9,_0x5dd92c)[_0x12068b('0xa')](function(){const _0x4a0b5c=_0x12068b;logger[_0x4a0b5c('0x13')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x3c63b9,_0x5dd92c,_0x536caf);})[_0x12068b('0x9')](function(_0x39e505){const _0x558a6e=_0x12068b;logger[_0x558a6e('0x13')](util[_0x558a6e('0x1c')](_0x39e505,{'showHidden':![],'depth':null}));});});},Migration[_0x12d782('0x15')][_0x12d782('0xc')]=function(_0x1233ea){const _0x538190=_0x12d782;this[_0x538190('0x1d')][_0x538190('0x0')](function(){return _0x1233ea();});},module[_0x12d782('0x11')]={'up':function(_0x2348b9){return new Promise(function(_0x74379d){const _0x47e3de=a998_0x45aa,_0x536d09=new Migration(_0x2348b9);_0x536d09[_0x47e3de('0x4')](_0x47e3de('0xe')),_0x536d09[_0x47e3de('0xc')](_0x74379d);});},'down':function(){}};