7b48c03017b59892646131bfb6ca72074f193a5a
[motion.git] / server / api / dashboard / dashboard.controller.js
1 var _0x98ef=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x61\x70\x69","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x6C\x6F\x67\x67\x65\x72\x2E\x6A\x73","\x44\x61\x73\x68\x62\x6F\x61\x72\x64","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x69\x6E\x64\x65\x78","\x63\x61\x74\x63\x68","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x74\x68\x65\x6E","\x71\x75\x65\x72\x79","\x67\x65\x74\x51\x75\x65\x72\x79","\x66\x69\x6E\x64\x41\x6E\x64\x43\x6F\x75\x6E\x74\x41\x6C\x6C","\x67\x65\x74\x43\x75\x73\x74\x6F\x6D\x44\x61\x73\x68\x62\x6F\x61\x72\x64\x56\x61\x6C\x75\x65\x73","\x63\x75\x73\x74\x6F\x6D\x44\x61\x73\x68\x62\x6F\x61\x72\x64\x56\x61\x6C\x75\x65\x73","\x69\x64","\x70\x61\x72\x61\x6D\x73","\x75\x73\x65\x72","\x61\x6D\x69","\x6C\x6F\x63\x61\x6C\x73","\x61\x70\x70","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x69\x6E\x69\x74","\x61\x76\x67\x44\x75\x72\x61\x74\x69\x6F\x6E","\x6F\x75\x74\x62\x6F\x75\x6E\x64","\x61\x6E\x73\x77\x65\x72\x52\x61\x74\x65","\x61\x6E\x73\x77\x65\x72\x65\x64","\x67\x6C\x6F\x62\x61\x6C\x44\x75\x72\x61\x74\x69\x6F\x6E","\x53\x45\x4C\x45\x43\x54\x20\x41\x56\x47\x28\x64\x75\x72\x61\x74\x69\x6F\x6E\x29\x20\x61\x73\x20\x61\x76\x67\x44\x75\x72\x61\x74\x69\x6F\x6E\x20\x0A\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x63\x61\x6C\x6C\x20\x0A\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x74\x79\x70\x65\x3D\x22\x6F\x75\x74\x62\x6F\x75\x6E\x64\x22","\x53\x45\x4C\x45\x43\x54","\x51\x75\x65\x72\x79\x54\x79\x70\x65\x73","\x6D\x61\x6E\x75\x61\x6C\x4F\x75\x74\x62\x6F\x75\x6E\x64","\x53\x45\x4C\x45\x43\x54\x20\x53\x55\x4D\x28\x64\x75\x72\x61\x74\x69\x6F\x6E\x29\x20\x61\x73\x20\x67\x6C\x6F\x62\x61\x6C\x44\x75\x72\x61\x74\x69\x6F\x6E\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x63\x61\x6C\x6C\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x74\x79\x70\x65\x20\x3D\x20\x27\x6F\x75\x74\x62\x6F\x75\x6E\x64\x27\x3B","\x53\x45\x4C\x45\x43\x54\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x6D\x61\x6E\x75\x61\x6C\x4F\x75\x74\x62\x6F\x75\x6E\x64\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x63\x61\x6C\x6C\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x74\x79\x70\x65\x20\x3D\x20\x27\x6F\x75\x74\x62\x6F\x75\x6E\x64\x27\x3B","\x71\x75\x65\x75\x65","\x71\x75\x65\x75\x65\x73","\x75\x6E\x6D\x61\x6E\x61\x67\x65\x64","\x66\x6F\x72\x45\x61\x63\x68","\x53\x45\x4C\x45\x43\x54\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x61\x6E\x73\x77\x65\x72\x65\x64\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x63\x61\x6C\x6C\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x64\x69\x73\x70\x6F\x73\x69\x74\x69\x6F\x6E\x20\x3D\x20\x27\x41\x4E\x53\x57\x45\x52\x27\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x41\x4E\x44\x20\x74\x79\x70\x65\x20\x3D\x20\x27\x6F\x75\x74\x62\x6F\x75\x6E\x64\x27\x3B","\x74\x61\x6C\x6B\x74\x69\x6D\x65","\x53\x45\x4C\x45\x43\x54\x20\x71\x75\x65\x75\x65\x2C\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x75\x6E\x6D\x61\x6E\x61\x67\x65\x64\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x71\x75\x65\x75\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x65\x78\x69\x74\x20\x3D\x20\x31\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x47\x52\x4F\x55\x50\x20\x42\x59\x20\x71\x75\x65\x75\x65\x3B","\x68\x6F\x6C\x64\x74\x69\x6D\x65","\x53\x45\x4C\x45\x43\x54\x20\x71\x75\x65\x75\x65\x2C\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x63\x61\x6C\x6C\x73\x2C\x20\x53\x55\x4D\x28\x74\x61\x6C\x6B\x74\x69\x6D\x65\x29\x20\x61\x73\x20\x74\x61\x6C\x6B\x74\x69\x6D\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x61\x67\x65\x6E\x74\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x61\x67\x65\x6E\x74\x63\x6F\x6D\x70\x6C\x65\x74\x65\x20\x3D\x20\x31\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x47\x52\x4F\x55\x50\x20\x42\x59\x20\x71\x75\x65\x75\x65\x3B","\x63\x6F\x6D\x70\x6C\x65\x74\x65","\x53\x45\x4C\x45\x43\x54\x20\x71\x75\x65\x75\x65\x2C\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x63\x61\x6C\x6C\x73\x2C\x20\x53\x55\x4D\x28\x68\x6F\x6C\x64\x74\x69\x6D\x65\x29\x20\x61\x73\x20\x68\x6F\x6C\x64\x74\x69\x6D\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x61\x67\x65\x6E\x74\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x61\x67\x65\x6E\x74\x63\x6F\x6D\x70\x6C\x65\x74\x65\x20\x3D\x20\x31\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x47\x52\x4F\x55\x50\x20\x42\x59\x20\x71\x75\x65\x75\x65\x3B","\x61\x62\x61\x6E\x64\x6F\x6E","\x53\x45\x4C\x45\x43\x54\x20\x71\x75\x65\x75\x65\x2C\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x63\x6F\x6D\x70\x6C\x65\x74\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x71\x75\x65\x75\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x63\x6F\x6D\x70\x6C\x65\x74\x65\x20\x3D\x20\x31\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x47\x52\x4F\x55\x50\x20\x42\x59\x20\x71\x75\x65\x75\x65\x3B","\x61\x63\x74\x69\x76\x65","\x53\x45\x4C\x45\x43\x54\x20\x71\x75\x65\x75\x65\x2C\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x61\x62\x61\x6E\x64\x6F\x6E\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x71\x75\x65\x75\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x61\x62\x61\x6E\x64\x6F\x6E\x20\x3D\x20\x31\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x47\x52\x4F\x55\x50\x20\x42\x59\x20\x71\x75\x65\x75\x65\x3B","\x77\x61\x69\x74\x69\x6E\x67","\x53\x45\x4C\x45\x43\x54\x20\x71\x75\x65\x75\x65\x2C\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x61\x63\x74\x69\x76\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x71\x75\x65\x75\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x65\x78\x69\x74\x20\x3D\x20\x30\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x41\x4E\x44\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x61\x62\x61\x6E\x64\x6F\x6E\x20\x3D\x20\x30\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x41\x4E\x44\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x63\x6F\x6D\x70\x6C\x65\x74\x65\x20\x3D\x20\x30\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x41\x4E\x44\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6C\x65\x61\x76\x65\x41\x74\x20\x49\x53\x20\x4E\x4F\x54\x20\x4E\x55\x4C\x4C\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x47\x52\x4F\x55\x50\x20\x42\x59\x20\x71\x75\x65\x75\x65\x3B","\x6E\x61\x6D\x65","\x6B\x65\x79\x42\x79","\x53\x45\x4C\x45\x43\x54\x20\x71\x75\x65\x75\x65\x2C\x20\x63\x6F\x75\x6E\x74\x28\x2A\x29\x20\x61\x73\x20\x77\x61\x69\x74\x69\x6E\x67\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x46\x52\x4F\x4D\x20\x72\x65\x70\x6F\x72\x74\x5F\x71\x75\x65\x75\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x57\x48\x45\x52\x45\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6C\x65\x61\x76\x65\x41\x74\x20\x49\x53\x20\x4E\x55\x4C\x4C\x20\x61\x6E\x64\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x65\x78\x69\x74\x20\x3D\x20\x66\x61\x6C\x73\x65\x20\x0A\x20\x20\x20\x20\x20\x20\x20\x20\x47\x52\x4F\x55\x50\x20\x42\x59\x20\x71\x75\x65\x75\x65\x3B","\x66\x69\x6E\x64\x41\x6C\x6C","\x61\x6C\x6C","\x73\x68\x6F\x77","\x66\x69\x6E\x64\x42\x79\x49\x64","\x63\x72\x65\x61\x74\x65","\x62\x6F\x64\x79","\x63\x6C\x6F\x6E\x65","\x64\x61\x74\x61\x56\x61\x6C\x75\x65\x73","\x65\x64\x69\x74\x61\x62\x6C\x65","\x64\x65\x66\x61\x75\x6C\x74\x45\x6E\x74\x72\x79","\x6D\x6F\x64\x65\x6C","\x70\x61\x72\x73\x65","\x74\x69\x74\x6C\x65","\x5F\x63\x6F\x70\x79\x5F","\x67\x65\x74\x55\x54\x43\x4D\x69\x6C\x6C\x69\x73\x65\x63\x6F\x6E\x64\x73","\x73\x74\x72\x69\x6E\x67\x69\x66\x79","\x75\x70\x64\x61\x74\x65","\x6D\x65\x72\x67\x65","\x73\x61\x76\x65","\x64\x65\x73\x74\x72\x6F\x79","\x62\x75\x6C\x6B\x44\x65\x73\x74\x72\x6F\x79","\x69\x64\x73","\x73\x74\x61\x63\x6B","\x65\x72\x72\x6F\x72"];_0x98ef[0];var _=require(_0x98ef[1]);var util=require(_0x98ef[2]);var Util=require(_0x98ef[3]);var logger=require(_0x98ef[5])(_0x98ef[4]);var Dashboard=require(_0x98ef[7])[_0x98ef[6]];var VoiceQueue=require(_0x98ef[7])[_0x98ef[8]];var sequelize=require(_0x98ef[7])[_0x98ef[9]];exports[_0x98ef[10]]= function(_0x70f4x8,_0x70f4x9,_0x70f4xa){return Dashboard[_0x98ef[17]](Util[_0x98ef[16]](_0x70f4x8[_0x98ef[15]]))[_0x98ef[14]](function(_0x70f4xc){_0x70f4x9[_0x98ef[13]](200)[_0x98ef[12]](_0x70f4xc)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[18]]= function(_0x70f4x8,_0x70f4x9,_0x70f4xa){_0x70f4x8[_0x98ef[25]][_0x98ef[24]][_0x98ef[23]][_0x98ef[12]]({message:_0x98ef[19],id:_0x70f4x8[_0x98ef[21]][_0x98ef[20]],user:_0x70f4x8[_0x98ef[22]]});return _0x70f4x9[_0x98ef[26]](201)};exports[_0x98ef[27]]= function(_0x70f4x8,_0x70f4x9,_0x70f4xa){var _0x70f4xd={queues:{},outbound:{}};return VoiceQueue[_0x98ef[59]]({attributes:[_0x98ef[56]],raw:true})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xd[_0x98ef[40]]= _[_0x98ef[57]](_0x70f4xe,_0x98ef[56]);return sequelize[_0x98ef[15]](_0x98ef[58],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xe[_0x98ef[42]](function(_0x70f4xf){if(_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]]){_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]][_0x98ef[54]]= _0x70f4xf[_0x98ef[54]]}});return sequelize[_0x98ef[15]](_0x98ef[55],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xe[_0x98ef[42]](function(_0x70f4xf){if(_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]]){_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]][_0x98ef[52]]= _0x70f4xf[_0x98ef[52]]}});return sequelize[_0x98ef[15]](_0x98ef[53],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xe[_0x98ef[42]](function(_0x70f4xf){if(_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]]){_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]][_0x98ef[50]]= _0x70f4xf[_0x98ef[50]]}});return sequelize[_0x98ef[15]](_0x98ef[51],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xe[_0x98ef[42]](function(_0x70f4xf){if(_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]]){_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]][_0x98ef[48]]= _0x70f4xf[_0x98ef[48]]}});return sequelize[_0x98ef[15]](_0x98ef[49],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xe[_0x98ef[42]](function(_0x70f4xf){if(_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]]){_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]][_0x98ef[46]]= _0x70f4xf[_0x98ef[46]]}});return sequelize[_0x98ef[15]](_0x98ef[47],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xe[_0x98ef[42]](function(_0x70f4xf){if(_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]]){_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]][_0x98ef[44]]= _0x70f4xf[_0x98ef[44]]}});return sequelize[_0x98ef[15]](_0x98ef[45],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xe[_0x98ef[42]](function(_0x70f4xf){if(_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]]){_0x70f4xd[_0x98ef[40]][_0x70f4xf[_0x98ef[39]]][_0x98ef[41]]= _0x70f4xf[_0x98ef[41]]}});return sequelize[_0x98ef[15]](_0x98ef[43],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xd[_0x98ef[29]][_0x98ef[31]]= _0x70f4xe[0][_0x98ef[31]];return sequelize[_0x98ef[15]](_0x98ef[38],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xd[_0x98ef[29]][_0x98ef[36]]= _0x70f4xe[0][_0x98ef[36]];return sequelize[_0x98ef[15]](_0x98ef[37],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xd[_0x98ef[29]][_0x98ef[32]]= _0x70f4xe[0][_0x98ef[32]]|| 0;return sequelize[_0x98ef[15]](_0x98ef[33],{type:sequelize[_0x98ef[35]][_0x98ef[34]]})})[_0x98ef[14]](function(_0x70f4xe){_0x70f4xd[_0x98ef[29]][_0x98ef[28]]= _0x70f4xe[0][_0x98ef[28]]|| 0;_0x70f4xd[_0x98ef[29]][_0x98ef[30]]= _0x70f4xd[_0x98ef[29]][_0x98ef[28]]?((_0x70f4xd[_0x98ef[29]][_0x98ef[31]]/ _0x70f4xd[_0x98ef[29]][_0x98ef[32]])* 100):0;return _0x70f4x9[_0x98ef[13]](200)[_0x98ef[12]](_0x70f4xd)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[60]]= function(_0x70f4x8,_0x70f4x9){return Dashboard[_0x98ef[59]]()[_0x98ef[14]](function(_0x70f4x10){if(!_0x70f4x10){return _0x70f4x9[_0x98ef[26]](404)};return _0x70f4x9[_0x98ef[13]](200)[_0x98ef[12]](_0x70f4x10)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[61]]= function(_0x70f4x8,_0x70f4x9){return Dashboard[_0x98ef[62]](_0x70f4x8[_0x98ef[21]][_0x98ef[20]])[_0x98ef[14]](function(_0x70f4x11){if(!_0x70f4x11){return _0x70f4x9[_0x98ef[26]](404)};return _0x70f4x9[_0x98ef[12]](_0x70f4x11)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[63]]= function(_0x70f4x8,_0x70f4x9){return Dashboard[_0x98ef[63]](_0x70f4x8[_0x98ef[64]])[_0x98ef[14]](function(_0x70f4x11){return _0x70f4x9[_0x98ef[13]](201)[_0x98ef[12]](_0x70f4x11)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[65]]= function(_0x70f4x8,_0x70f4x9){return Dashboard[_0x98ef[62]](_0x70f4x8[_0x98ef[21]][_0x98ef[20]])[_0x98ef[14]](function(_0x70f4x11){var _0x70f4x12=_0x70f4x11[_0x98ef[66]];delete _0x70f4x12[_0x98ef[20]];_0x70f4x12[_0x98ef[67]]= true;_0x70f4x12[_0x98ef[68]]= false;var _0x70f4x13=JSON[_0x98ef[70]](_0x70f4x12[_0x98ef[69]]);if(_0x70f4x8[_0x98ef[64]][_0x98ef[56]]){_0x70f4x12[_0x98ef[56]]= _0x70f4x8[_0x98ef[64]][_0x98ef[56]];_0x70f4x13[_0x98ef[71]]= _0x70f4x8[_0x98ef[64]][_0x98ef[56]]}else {_0x70f4x12[_0x98ef[56]]= _0x70f4x13[_0x98ef[71]]= _0x70f4x12[_0x98ef[56]]+ _0x98ef[72]+  new Date()[_0x98ef[73]]()};_0x70f4x12[_0x98ef[69]]= JSON[_0x98ef[74]](_0x70f4x13);return Dashboard[_0x98ef[63]](_0x70f4x12)})[_0x98ef[14]](function(_0x70f4x11){return _0x70f4x9[_0x98ef[13]](201)[_0x98ef[12]](_0x70f4x11)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[75]]= function(_0x70f4x8,_0x70f4x9){if(_0x70f4x8[_0x98ef[64]][_0x98ef[20]]){delete _0x70f4x8[_0x98ef[64]][_0x98ef[20]]};return Dashboard[_0x98ef[62]](_0x70f4x8[_0x98ef[21]][_0x98ef[20]])[_0x98ef[14]](function(_0x70f4x11){if(!_0x70f4x11){return _0x70f4x9[_0x98ef[26]](404)};if(_0x70f4x8[_0x98ef[64]][_0x98ef[56]]){var _0x70f4x13=JSON[_0x98ef[70]](_0x70f4x11[_0x98ef[69]]);_0x70f4x13[_0x98ef[71]]= _0x70f4x8[_0x98ef[64]][_0x98ef[56]];_0x70f4x11[_0x98ef[69]]= JSON[_0x98ef[74]](_0x70f4x13)};var _0x70f4x14=_[_0x98ef[76]](_0x70f4x11,_0x70f4x8[_0x98ef[64]]);return _0x70f4x14[_0x98ef[77]]()})[_0x98ef[14]](function(_0x70f4x11){return _0x70f4x9[_0x98ef[13]](200)[_0x98ef[12]](_0x70f4x11)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[78]]= function(_0x70f4x8,_0x70f4x9){return Dashboard[_0x98ef[62]](_0x70f4x8[_0x98ef[21]][_0x98ef[20]])[_0x98ef[14]](function(_0x70f4x11){if(!_0x70f4x11){return _0x70f4x9[_0x98ef[26]](404)};return _0x70f4x11[_0x98ef[78]]()})[_0x98ef[14]](function(){return _0x70f4x9[_0x98ef[26]](204)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};exports[_0x98ef[79]]= function(_0x70f4x8,_0x70f4x9){return Dashboard[_0x98ef[78]]({where:{id:_0x70f4x8[_0x98ef[15]][_0x98ef[80]]},individualHooks:true})[_0x98ef[14]](function(){return _0x70f4x9[_0x98ef[26]](204)})[_0x98ef[11]](function(_0x70f4xb){return handleError(_0x70f4x9,_0x70f4xb)})};function handleError(_0x70f4x9,_0x70f4xb){logger[_0x98ef[82]](_0x70f4xb[_0x98ef[81]]);return _0x70f4x9[_0x98ef[13]](500)[_0x98ef[12]](_0x70f4xb)}