Built motion from commit d3d6ca497.|1.0.32
[motion.git] / server / config / triggers / sms.js
1 var _0xda00=["\x6C\x6F\x64\x61\x73\x68","\x72\x65\x71\x75\x65\x73\x74\x2D\x70\x72\x6F\x6D\x69\x73\x65","\x6D\x75\x73\x74\x61\x63\x68\x65","\x6D\x6F\x74\x69\x6F\x6E","\x2E\x2E\x2F\x6C\x6F\x67\x67\x65\x72\x2E\x6A\x73","\x54\x65\x6D\x70\x6C\x61\x74\x65","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x53\x6D\x73\x52\x6F\x6F\x6D","\x4D\x61\x69\x6C\x41\x63\x63\x6F\x75\x6E\x74","\x53\x6D\x73\x41\x63\x63\x6F\x75\x6E\x74","\x53\x6D\x73\x4D\x65\x73\x73\x61\x67\x65","\x4D\x61\x69\x6C\x4D\x65\x73\x73\x61\x67\x65","\x54\x72\x69\x67\x67\x65\x72\x20\x53\x6D\x73\x20\x49\x6E\x69\x74\x69\x61\x6C\x69\x7A\x61\x74\x69\x6F\x6E\x2E\x2E\x2E","\x69\x6E\x66\x6F","\x74\x61\x67","\x70\x72\x6F\x74\x6F\x74\x79\x70\x65","\x53\x6D\x73\x20\x74\x72\x69\x67\x67\x65\x72\x20\x74\x61\x67\x20\x65\x72\x72\x6F\x72","\x73\x74\x61\x63\x6B","\x65\x72\x72\x6F\x72","\x63\x61\x74\x63\x68","\x3B","\x73\x70\x6C\x69\x74","\x64\x61\x74\x61\x31","\x53\x6D\x73\x52\x6F\x6F\x6D\x49\x64","\x75\x70\x64\x61\x74\x65","\x63\x6C\x6F\x73\x65","\x53\x6D\x73\x20\x74\x72\x69\x67\x67\x65\x72\x20\x63\x6C\x6F\x73\x65\x20\x65\x72\x72\x6F\x72","\x43\x4C\x4F\x53\x45\x44","\x61\x63\x63\x6F\x75\x6E\x74\x53\x6D\x73","\x53\x6D\x73\x20\x74\x72\x69\x67\x67\x65\x72\x20\x73\x65\x6E\x64\x20\x73\x6D\x73\x20\x62\x79\x20\x61\x63\x63\x6F\x75\x6E\x74\x20\x65\x72\x72\x6F\x72","\x70\x68\x6F\x6E\x65","\x64\x61\x74\x61\x32","\x64\x61\x74\x61\x33","\x53\x45\x4E\x44\x49\x4E\x47","\x69\x64","\x63\x72\x65\x61\x74\x65\x53\x6D\x73\x4D\x65\x73\x73\x61\x67\x65","\x73\x65\x6E\x64","\x74\x68\x65\x6E","\x66\x69\x6E\x64\x42\x79\x49\x64","\x65\x78\x70\x6F\x72\x74\x73"];const _=require(_0xda00[0]);const rp=require(_0xda00[1]);const Mustache=require(_0xda00[2]);var logger=require(_0xda00[4])(_0xda00[3]);const Template=require(_0xda00[6])[_0xda00[5]];const SmsRoom=require(_0xda00[6])[_0xda00[7]];const MailAccount=require(_0xda00[6])[_0xda00[8]];const SmsAccount=require(_0xda00[6])[_0xda00[9]];const SmsMessage=require(_0xda00[6])[_0xda00[10]];const MailMessage=require(_0xda00[6])[_0xda00[11]];function Sms(){logger[_0xda00[13]](_0xda00[12])}Sms[_0xda00[15]][_0xda00[14]]= function(_0x176fxc,_0x176fxd){return SmsRoom[_0xda00[24]]({tags:_0x176fxc[_0xda00[22]][_0xda00[21]](_0xda00[20])},{where:{id:_0x176fxd[_0xda00[23]]}})[_0xda00[19]](function(_0x176fxe){logger[_0xda00[18]](_0xda00[16],_0x176fxe[_0xda00[17]])})};Sms[_0xda00[15]][_0xda00[25]]= function(_0x176fxc,_0x176fxd){return SmsRoom[_0xda00[24]]({status:_0xda00[27],disposition:_0x176fxc[_0xda00[22]]|| null},{individualHooks:true,where:{id:_0x176fxd[_0xda00[23]]}})[_0xda00[19]](function(_0x176fxe){logger[_0xda00[18]](_0xda00[26],_0x176fxe[_0xda00[17]])})};Sms[_0xda00[15]][_0xda00[28]]= function(_0x176fxc,_0x176fxd){return SmsAccount[_0xda00[38]](_0x176fxc[_0xda00[22]])[_0xda00[37]](function(_0x176fxf){var _0x176fx10={from:_0x176fxf[_0xda00[30]],to:_0x176fxc[_0xda00[31]],body:_0x176fxc[_0xda00[32]],status:_0xda00[33],auto:true,SmsAccountId:_0x176fxf[_0xda00[34]]};process[_0xda00[36]]({message:_0xda00[35],doc:_0x176fx10})})[_0xda00[19]](function(_0x176fxe){logger[_0xda00[18]](_0xda00[29],_0x176fxe[_0xda00[17]])})};module[_0xda00[39]]= Sms