Built motion from commit 459747fdfe53bbf13fbede61eeaffea1f1438f86. Version 3.0.0...
[motion-next.git] / server / migrations / 2.3.3.js
index 355888a..680589a 100644 (file)
@@ -1 +1 @@
-const a976_0x4ffb=['TEXT','removeIndex\x20%s\x20%s','then','sequence','chat_applications','Removed\x20column\x20%s\x20from\x20%s','addIndex','catch','fax_applications','openchannel_applications','finally','prototype','changeColumn','stringify','../config/logger','addColumn','renameColumn','addIndex\x20%s\x20%s\x20%s','inspect','join','removeIndex','query','tail','dropTable','info','sequelize','sms_applications','final','appdata','queryInterface','migration','enqueue','Changed\x20column\x20%s\x20in\x20table\x20%s'];(function(_0x4661be,_0x4ffb8e){const _0x3f2965=function(_0x12779e){while(--_0x12779e){_0x4661be['push'](_0x4661be['shift']());}};_0x3f2965(++_0x4ffb8e);}(a976_0x4ffb,0x170));const a976_0x3f29=function(_0x4661be,_0x4ffb8e){_0x4661be=_0x4661be-0x0;let _0x3f2965=a976_0x4ffb[_0x4661be];return _0x3f2965;};const _0x26c3a9=a976_0x3f29;'use strict';const util=require('util'),logger=require(_0x26c3a9('0x9'))(_0x26c3a9('0x19')),Sequence=function(){};Sequence[_0x26c3a9('0x6')][_0x26c3a9('0x1a')]=function(_0x12779e){const _0x44fd73=_0x26c3a9;this[_0x44fd73('0x11')]=this[_0x44fd73('0x11')]?this['tail'][_0x44fd73('0x5')](_0x12779e):_0x12779e();};const Migration=function(_0x13694c){const _0x823007=_0x26c3a9;this['queryInterface']=_0x13694c,this[_0x823007('0x1f')]=new Sequence();};Migration[_0x26c3a9('0x6')]['changeColumn']=function(_0x46984f,_0xf10a79,_0x17c752){const _0x26edd4=_0x26c3a9,_0x3b1b83=this;this['sequence'][_0x26edd4('0x1a')](function(){const _0x3aa7d3=_0x26edd4;return _0x3b1b83[_0x3aa7d3('0x18')][_0x3aa7d3('0x7')](_0x46984f,_0xf10a79,_0x17c752)[_0x3aa7d3('0x1e')](function(){const _0x51eb23=_0x3aa7d3;logger[_0x51eb23('0x13')](_0x51eb23('0x1b'),_0xf10a79,_0x46984f);})['catch'](function(_0x17183e){const _0xaa541c=_0x3aa7d3;logger[_0xaa541c('0x13')](JSON[_0xaa541c('0x8')](_0x17183e));});});},Migration['prototype']['addColumn']=function(_0x4a520c,_0x8ed36e,_0x212731){const _0x5a4ae0=_0x26c3a9,_0x46dcb4=this;this[_0x5a4ae0('0x1f')][_0x5a4ae0('0x1a')](function(){const _0x34866f=_0x5a4ae0;return _0x46dcb4[_0x34866f('0x18')][_0x34866f('0xa')](_0x4a520c,_0x8ed36e,_0x212731)[_0x34866f('0x1e')](function(){const _0x2ecba2=_0x34866f;logger[_0x2ecba2('0x13')]('Added\x20column\x20%s\x20to\x20%s',_0x8ed36e,_0x4a520c);})[_0x34866f('0x2')](function(_0x2764f4){const _0x21ba0f=_0x34866f;logger[_0x21ba0f('0x13')](JSON[_0x21ba0f('0x8')](_0x2764f4));});});},Migration[_0x26c3a9('0x6')][_0x26c3a9('0x12')]=function(_0x5e2873){const _0x42512b=_0x26c3a9,_0x11c1e0=this;this[_0x42512b('0x1f')][_0x42512b('0x1a')](function(){const _0x14af6f=_0x42512b;return _0x11c1e0[_0x14af6f('0x18')][_0x14af6f('0x12')](_0x5e2873,{'force':!![]})['then'](function(){const _0x223a76=_0x14af6f;logger[_0x223a76('0x13')]('table\x20dropped\x20%s',_0x5e2873);})[_0x14af6f('0x2')](function(_0x17bf0e){const _0x9ddc69=_0x14af6f;logger['info'](JSON[_0x9ddc69('0x8')](_0x17bf0e));});});},Migration['prototype'][_0x26c3a9('0x1')]=function(_0x272821,_0xfa3790,_0x47d24c){const _0x5b49db=_0x26c3a9,_0x222db6=this;this[_0x5b49db('0x1f')][_0x5b49db('0x1a')](function(){const _0x3f5614=_0x5b49db;return _0x222db6[_0x3f5614('0x18')][_0x3f5614('0x1')](_0x272821,_0xfa3790,{'indexName':_0x47d24c})[_0x3f5614('0x1e')](function(){const _0x2f6b63=_0x3f5614;logger[_0x2f6b63('0x13')](_0x2f6b63('0xc'),_0x272821,_0xfa3790[_0x2f6b63('0xe')](','),_0x47d24c);})[_0x3f5614('0x2')](function(_0x156e9c){const _0x585009=_0x3f5614;logger[_0x585009('0x13')](JSON['stringify'](_0x156e9c));});});},Migration[_0x26c3a9('0x6')][_0x26c3a9('0xf')]=function(_0x539f78,_0x4605e6){const _0x32f3d2=_0x26c3a9,_0x29182d=this;this[_0x32f3d2('0x1f')][_0x32f3d2('0x1a')](function(){const _0x60e65a=_0x32f3d2;return _0x29182d[_0x60e65a('0x18')][_0x60e65a('0xf')](_0x539f78,_0x4605e6)[_0x60e65a('0x1e')](function(){const _0x1d24b9=_0x60e65a;logger[_0x1d24b9('0x13')](_0x1d24b9('0x1d'),_0x539f78,_0x4605e6);})[_0x60e65a('0x2')](function(_0x191199){const _0x1d8a62=_0x60e65a;logger[_0x1d8a62('0x13')](JSON[_0x1d8a62('0x8')](_0x191199));});});},Migration[_0x26c3a9('0x6')][_0x26c3a9('0x10')]=function(_0x4534cc){const _0x2eeffb=_0x26c3a9,_0x592dd4=this;this[_0x2eeffb('0x1f')][_0x2eeffb('0x1a')](function(){const _0x91a497=_0x2eeffb;return _0x592dd4['queryInterface'][_0x91a497('0x14')][_0x91a497('0x10')](_0x4534cc)[_0x91a497('0x1e')](function(){const _0x3e6111=_0x91a497;logger[_0x3e6111('0x13')]('query\x20%s',_0x4534cc);})[_0x91a497('0x2')](function(_0x3bea2e){const _0x1481be=_0x91a497;logger[_0x1481be('0x13')](JSON[_0x1481be('0x8')](_0x3bea2e));});});},Migration[_0x26c3a9('0x6')]['removeColumn']=function(_0x497a92,_0x18cff6){const _0x2caefd=_0x26c3a9,_0x4f00a5=this;this[_0x2caefd('0x1f')][_0x2caefd('0x1a')](function(){const _0x148672=_0x2caefd;return _0x4f00a5[_0x148672('0x18')]['removeColumn'](_0x497a92,_0x18cff6)[_0x148672('0x1e')](function(){const _0x1fa929=_0x148672;logger[_0x1fa929('0x13')](_0x1fa929('0x0'),_0x18cff6,_0x497a92);})[_0x148672('0x2')](function(_0x21cba4){const _0x1159f0=_0x148672;logger[_0x1159f0('0x13')](util[_0x1159f0('0xd')](_0x21cba4,{'showHidden':![],'depth':null}));});});},Migration[_0x26c3a9('0x6')][_0x26c3a9('0xb')]=function(_0x59060a,_0xe186c3,_0x261ede){const _0x3b4f31=_0x26c3a9,_0x5d14ca=this;this['sequence'][_0x3b4f31('0x1a')](function(){const _0x1ce6bb=_0x3b4f31;return _0x5d14ca[_0x1ce6bb('0x18')]['renameColumn'](_0x59060a,_0xe186c3,_0x261ede)[_0x1ce6bb('0x1e')](function(){const _0x13970=_0x1ce6bb;logger[_0x13970('0x13')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0xe186c3,_0x261ede,_0x59060a);})[_0x1ce6bb('0x2')](function(_0x4636b3){const _0x1b8f8b=_0x1ce6bb;logger[_0x1b8f8b('0x13')](util[_0x1b8f8b('0xd')](_0x4636b3,{'showHidden':![],'depth':null}));});});},Migration[_0x26c3a9('0x6')][_0x26c3a9('0x16')]=function(_0x4e81f4){const _0xb1de9b=_0x26c3a9;this[_0xb1de9b('0x1f')][_0xb1de9b('0x1a')](function(){return _0x4e81f4();});},module['exports']={'up':function(_0x5cc705,_0x2355a9){return new Promise(function(_0x2f5f0d){const _0x478496=a976_0x3f29,_0x265f0b=new Migration(_0x5cc705);_0x265f0b[_0x478496('0x10')]('ALTER\x20TABLE\x20tools_canned_answers\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;'),_0x265f0b[_0x478496('0x7')](_0x478496('0x20'),_0x478496('0x17'),{'type':_0x2355a9[_0x478496('0x1c')]()}),_0x265f0b[_0x478496('0x7')](_0x478496('0x3'),_0x478496('0x17'),{'type':_0x2355a9[_0x478496('0x1c')]()}),_0x265f0b[_0x478496('0x7')]('mail_applications',_0x478496('0x17'),{'type':_0x2355a9[_0x478496('0x1c')]()}),_0x265f0b[_0x478496('0x7')](_0x478496('0x4'),_0x478496('0x17'),{'type':_0x2355a9[_0x478496('0x1c')]()}),_0x265f0b[_0x478496('0x7')](_0x478496('0x15'),_0x478496('0x17'),{'type':_0x2355a9[_0x478496('0x1c')]()}),_0x265f0b[_0x478496('0x16')](_0x2f5f0d);});},'down':function(){}};
\ No newline at end of file
+const a976_0x28ae=['final','removeIndex','addColumn','join','catch','fax_applications','stringify','renameColumn','addIndex\x20%s\x20%s\x20%s','TEXT','mail_applications','tail','addIndex','sequence','migration','inspect','changeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','dropTable','info','ALTER\x20TABLE\x20tools_canned_answers\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;','prototype','query','Added\x20column\x20%s\x20to\x20%s','appdata','exports','table\x20dropped\x20%s','sms_applications','../config/logger','queryInterface','removeIndex\x20%s\x20%s','query\x20%s','finally','removeColumn','enqueue','then','openchannel_applications'];(function(_0x32de52,_0x28ae8d){const _0x4d13bb=function(_0x4d1db6){while(--_0x4d1db6){_0x32de52['push'](_0x32de52['shift']());}};_0x4d13bb(++_0x28ae8d);}(a976_0x28ae,0x106));const a976_0x4d13=function(_0x32de52,_0x28ae8d){_0x32de52=_0x32de52-0x0;let _0x4d13bb=a976_0x28ae[_0x32de52];return _0x4d13bb;};const _0x180ab7=a976_0x4d13;'use strict';const util=require('util'),logger=require(_0x180ab7('0x19'))(_0x180ab7('0xb')),Sequence=function(){};Sequence[_0x180ab7('0x12')]['enqueue']=function(_0x4d1db6){const _0x5046ca=_0x180ab7;this[_0x5046ca('0x8')]=this[_0x5046ca('0x8')]?this[_0x5046ca('0x8')][_0x5046ca('0x1d')](_0x4d1db6):_0x4d1db6();};const Migration=function(_0x2a9b8c){this['queryInterface']=_0x2a9b8c,this['sequence']=new Sequence();};Migration[_0x180ab7('0x12')][_0x180ab7('0xd')]=function(_0x1c0565,_0x2e181d,_0x30808a){const _0x1eaf13=_0x180ab7,_0x6181bf=this;this[_0x1eaf13('0xa')]['enqueue'](function(){const _0x50e64a=_0x1eaf13;return _0x6181bf[_0x50e64a('0x1a')][_0x50e64a('0xd')](_0x1c0565,_0x2e181d,_0x30808a)[_0x50e64a('0x20')](function(){const _0x18fa2b=_0x50e64a;logger[_0x18fa2b('0x10')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x2e181d,_0x1c0565);})[_0x50e64a('0x1')](function(_0x4bb2f9){const _0x30b963=_0x50e64a;logger[_0x30b963('0x10')](JSON[_0x30b963('0x3')](_0x4bb2f9));});});},Migration['prototype'][_0x180ab7('0x24')]=function(_0x5e1bce,_0xc46d3,_0xf75edb){const _0x37df82=_0x180ab7,_0x4ca8f9=this;this[_0x37df82('0xa')][_0x37df82('0x1f')](function(){const _0x581925=_0x37df82;return _0x4ca8f9['queryInterface'][_0x581925('0x24')](_0x5e1bce,_0xc46d3,_0xf75edb)[_0x581925('0x20')](function(){const _0xa2a037=_0x581925;logger[_0xa2a037('0x10')](_0xa2a037('0x14'),_0xc46d3,_0x5e1bce);})[_0x581925('0x1')](function(_0xd79642){const _0x489a1e=_0x581925;logger['info'](JSON[_0x489a1e('0x3')](_0xd79642));});});},Migration[_0x180ab7('0x12')][_0x180ab7('0xf')]=function(_0x314014){const _0x3d9024=_0x180ab7,_0x5ce2b1=this;this[_0x3d9024('0xa')][_0x3d9024('0x1f')](function(){const _0x58b17c=_0x3d9024;return _0x5ce2b1[_0x58b17c('0x1a')][_0x58b17c('0xf')](_0x314014,{'force':!![]})[_0x58b17c('0x20')](function(){const _0x1b5db4=_0x58b17c;logger[_0x1b5db4('0x10')](_0x1b5db4('0x17'),_0x314014);})['catch'](function(_0x120bc2){const _0x51f75a=_0x58b17c;logger[_0x51f75a('0x10')](JSON[_0x51f75a('0x3')](_0x120bc2));});});},Migration[_0x180ab7('0x12')][_0x180ab7('0x9')]=function(_0x5a649f,_0x394148,_0x4bffe8){const _0x1efac9=_0x180ab7,_0x4fd967=this;this[_0x1efac9('0xa')]['enqueue'](function(){const _0xb3565=_0x1efac9;return _0x4fd967[_0xb3565('0x1a')][_0xb3565('0x9')](_0x5a649f,_0x394148,{'indexName':_0x4bffe8})[_0xb3565('0x20')](function(){const _0x1b3e31=_0xb3565;logger[_0x1b3e31('0x10')](_0x1b3e31('0x5'),_0x5a649f,_0x394148[_0x1b3e31('0x0')](','),_0x4bffe8);})[_0xb3565('0x1')](function(_0x53531d){const _0x573d6a=_0xb3565;logger[_0x573d6a('0x10')](JSON[_0x573d6a('0x3')](_0x53531d));});});},Migration[_0x180ab7('0x12')][_0x180ab7('0x23')]=function(_0x2b415e,_0x2783a3){const _0x1b205b=_0x180ab7,_0x261dd0=this;this[_0x1b205b('0xa')][_0x1b205b('0x1f')](function(){return _0x261dd0['queryInterface']['removeIndex'](_0x2b415e,_0x2783a3)['then'](function(){const _0x273cda=a976_0x4d13;logger['info'](_0x273cda('0x1b'),_0x2b415e,_0x2783a3);})['catch'](function(_0x4fbe25){const _0x4ea4ac=a976_0x4d13;logger[_0x4ea4ac('0x10')](JSON[_0x4ea4ac('0x3')](_0x4fbe25));});});},Migration[_0x180ab7('0x12')]['query']=function(_0x270da7){const _0x5872d3=_0x180ab7,_0xf7d61b=this;this[_0x5872d3('0xa')]['enqueue'](function(){const _0x5a10ba=_0x5872d3;return _0xf7d61b[_0x5a10ba('0x1a')]['sequelize'][_0x5a10ba('0x13')](_0x270da7)[_0x5a10ba('0x20')](function(){const _0x3d0289=_0x5a10ba;logger[_0x3d0289('0x10')](_0x3d0289('0x1c'),_0x270da7);})[_0x5a10ba('0x1')](function(_0x52d5be){const _0x5bc377=_0x5a10ba;logger[_0x5bc377('0x10')](JSON['stringify'](_0x52d5be));});});},Migration[_0x180ab7('0x12')][_0x180ab7('0x1e')]=function(_0x294478,_0x158e61){const _0x1698a6=_0x180ab7,_0xaaf7ca=this;this['sequence'][_0x1698a6('0x1f')](function(){const _0x3ad482=_0x1698a6;return _0xaaf7ca[_0x3ad482('0x1a')][_0x3ad482('0x1e')](_0x294478,_0x158e61)[_0x3ad482('0x20')](function(){const _0x535978=_0x3ad482;logger[_0x535978('0x10')]('Removed\x20column\x20%s\x20from\x20%s',_0x158e61,_0x294478);})['catch'](function(_0x1a42e1){const _0x28743a=_0x3ad482;logger[_0x28743a('0x10')](util[_0x28743a('0xc')](_0x1a42e1,{'showHidden':![],'depth':null}));});});},Migration[_0x180ab7('0x12')][_0x180ab7('0x4')]=function(_0x15a01a,_0x2d8593,_0x2aaae7){const _0x45c0c0=_0x180ab7,_0x49dfda=this;this[_0x45c0c0('0xa')][_0x45c0c0('0x1f')](function(){const _0x10d2d5=_0x45c0c0;return _0x49dfda[_0x10d2d5('0x1a')]['renameColumn'](_0x15a01a,_0x2d8593,_0x2aaae7)[_0x10d2d5('0x20')](function(){const _0x11aee3=_0x10d2d5;logger[_0x11aee3('0x10')](_0x11aee3('0xe'),_0x2d8593,_0x2aaae7,_0x15a01a);})[_0x10d2d5('0x1')](function(_0x179992){const _0x32cda6=_0x10d2d5;logger['info'](util[_0x32cda6('0xc')](_0x179992,{'showHidden':![],'depth':null}));});});},Migration[_0x180ab7('0x12')]['final']=function(_0x123dc0){const _0x2bb9cf=_0x180ab7;this[_0x2bb9cf('0xa')][_0x2bb9cf('0x1f')](function(){return _0x123dc0();});},module[_0x180ab7('0x16')]={'up':function(_0xf8a2c3,_0x4505b1){return new Promise(function(_0x4c103e){const _0x399cd6=a976_0x4d13,_0x394e89=new Migration(_0xf8a2c3);_0x394e89[_0x399cd6('0x13')](_0x399cd6('0x11')),_0x394e89[_0x399cd6('0xd')]('chat_applications','appdata',{'type':_0x4505b1[_0x399cd6('0x6')]()}),_0x394e89[_0x399cd6('0xd')](_0x399cd6('0x2'),_0x399cd6('0x15'),{'type':_0x4505b1['TEXT']()}),_0x394e89[_0x399cd6('0xd')](_0x399cd6('0x7'),_0x399cd6('0x15'),{'type':_0x4505b1[_0x399cd6('0x6')]()}),_0x394e89[_0x399cd6('0xd')](_0x399cd6('0x21'),'appdata',{'type':_0x4505b1[_0x399cd6('0x6')]()}),_0x394e89[_0x399cd6('0xd')](_0x399cd6('0x18'),_0x399cd6('0x15'),{'type':_0x4505b1[_0x399cd6('0x6')]()}),_0x394e89[_0x399cd6('0x22')](_0x4c103e);});},'down':function(){}};
\ No newline at end of file