Built motion from commit aab208717af8d15f4fa224cdb6a202877019af9b. Version 3.0.0...
[motion-next.git] / server / config / seedContact.js
1 const a852_0x76af=['hopper2','then','@xcally.com','innocenzo.biondo','bulkCreate','catch','Biondo','push','CmHopper','hopper1','now','../mysqldb','finished\x20populating','CmContact','contacts1','Innocenzo','destroy','log','contacts2'];(function(_0x4b5934,_0x76af79){const _0x6a6051=function(_0x533869){while(--_0x533869){_0x4b5934['push'](_0x4b5934['shift']());}};_0x6a6051(++_0x76af79);}(a852_0x76af,0x1c0));const a852_0x6a60=function(_0x4b5934,_0x76af79){_0x4b5934=_0x4b5934-0x0;let _0x6a6051=a852_0x76af[_0x4b5934];return _0x6a6051;};const _0x42d9e1=a852_0x6a60;'use strict';const db=require(_0x42d9e1('0x0'))['db'],contacts=[],hopper=[],contacts2=[],hopper2=[];for(let i=0x1;i<=0x4b0;i+=0x1){contacts[_0x42d9e1('0xf')]({'id':i,'firstName':_0x42d9e1('0x4')+i,'lastName':_0x42d9e1('0xe')+i,'phone':0xf879fb460+i,'email':_0x42d9e1('0xb')+i+_0x42d9e1('0xa')});}for(let i=0x1;i<=0x4b0;i+=0x1){hopper[_0x42d9e1('0xf')]({'id':i,'active':![],'scheduledat':Date[_0x42d9e1('0x12')](),'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0,'ContactId':i,'ListId':0x1,'UserId':0x1,'VoiceQueueId':0x3fd,'createdAt':Date[_0x42d9e1('0x12')](),'updatedAt':Date[_0x42d9e1('0x12')]()});}for(let i=0x4b1;i<=0x960;i+=0x1){contacts2[_0x42d9e1('0xf')]({'id':i,'firstName':'Innocenzo'+i,'lastName':_0x42d9e1('0xe')+i,'phone':0xf879fb460+i,'email':'innocenzo.biondo'+i+_0x42d9e1('0xa')});}for(let i=0x4b1;i<=0x960;i+=0x1){hopper2[_0x42d9e1('0xf')]({'id':i,'active':![],'scheduledat':Date[_0x42d9e1('0x12')](),'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0,'ContactId':i,'ListId':0x1,'UserId':0x1,'VoiceQueueId':0x3fd,'createdAt':Date[_0x42d9e1('0x12')](),'updatedAt':Date[_0x42d9e1('0x12')]()});}db['CmContact']['destroy']({'where':{}})[_0x42d9e1('0x9')](function(){const _0x2c6e98=_0x42d9e1;return db[_0x2c6e98('0x2')][_0x2c6e98('0xc')](contacts);})['then'](function(){const _0x128e34=_0x42d9e1;return console[_0x128e34('0x6')](_0x128e34('0x1'),_0x128e34('0x3')),db['CmHopper'][_0x128e34('0x5')]({'where':{}});})[_0x42d9e1('0x9')](function(){const _0x440fde=_0x42d9e1;return db[_0x440fde('0x10')][_0x440fde('0xc')](hopper);})[_0x42d9e1('0x9')](function(){const _0x387535=_0x42d9e1;return console['log']('finished\x20populating',_0x387535('0x11')),db['CmContact'][_0x387535('0xc')](contacts2);})[_0x42d9e1('0x9')](function(){const _0x2b262c=_0x42d9e1;return console[_0x2b262c('0x6')](_0x2b262c('0x1'),_0x2b262c('0x7')),db[_0x2b262c('0x10')][_0x2b262c('0xc')](hopper2);})[_0x42d9e1('0x9')](function(){const _0x20e260=_0x42d9e1;console[_0x20e260('0x6')](_0x20e260('0x1'),_0x20e260('0x8'));})[_0x42d9e1('0xd')](function(_0x533869){const _0x3f7969=_0x42d9e1;console[_0x3f7969('0x6')](_0x533869);});