Built motion from commit 712a57186.|1.0.37
[motion.git] / server / api / report_chat_session / report_chat_session.socket.js
index 0dde329..b0098b8 100644 (file)
@@ -1 +1 @@
-var _0x953f=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x2E\x2F\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x2E\x65\x76\x65\x6E\x74\x73","\x52\x65\x70\x6F\x72\x74\x43\x68\x61\x74\x53\x65\x73\x73\x69\x6F\x6E","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x55\x73\x65\x72","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x6C\x6F\x64\x61\x73\x68","\x62\x6C\x75\x65\x62\x69\x72\x64","\x73\x61\x76\x65","\x72\x65\x6D\x6F\x76\x65","\x72\x65\x67\x69\x73\x74\x65\x72","\x6C\x65\x6E\x67\x74\x68","\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x3A","\x6F\x6E","\x64\x69\x73\x63\x6F\x6E\x6E\x65\x63\x74","\x72\x65\x6D\x6F\x76\x65\x4C\x69\x73\x74\x65\x6E\x65\x72","\x69\x64","\x6D\x61\x70","\x75\x6E\x69\x6F\x6E","\x66\x6F\x72\x45\x61\x63\x68","\x72\x6F\x77\x73","\x74\x68\x65\x6E","\x67\x65\x74\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x75\x73\x65\x72\x49\x64","\x66\x69\x6E\x64\x42\x79\x49\x64","\x75\x73\x65\x72","\x67\x65\x74\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73","\x61\x67\x65\x6E\x74","\x72\x6F\x6C\x65","\x45\x72\x72\x6F\x72\x20\x66\x69\x6C\x74\x65\x72\x69\x6E\x67\x20\x72\x65\x70\x6F\x72\x74\x20\x63\x68\x61\x74\x20\x73\x65\x73\x73\x69\x6F\x6E\x73\x20\x61\x66\x74\x65\x72\x20\x73\x61\x76\x65","\x6C\x6F\x67","\x63\x61\x74\x63\x68","\x61\x64\x6D\x69\x6E","\x6D\x65\x6D\x62\x65\x72\x69\x64","\x69\x6E\x63\x6C\x75\x64\x65\x73","\x71\x75\x65\x75\x65","\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x3A\x73\x61\x76\x65","\x65\x6D\x69\x74","\x61\x6C\x6C","\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x3A\x72\x65\x6D\x6F\x76\x65"];_0x953f[0];const ReportChatSessionEvents=require(_0x953f[1]);const ReportChatSession=require(_0x953f[3])[_0x953f[2]];const User=require(_0x953f[3])[_0x953f[4]];const Util=require(_0x953f[5]);const _=require(_0x953f[6]);const Promise=require(_0x953f[7]);var events=[_0x953f[8],_0x953f[9]];exports[_0x953f[10]]= function(_0x922cx8){for(var _0x922cx9=0,_0x922cxa=events[_0x953f[11]];_0x922cx9< _0x922cxa;_0x922cx9++){var _0x922cxb=events[_0x922cx9];var _0x922cxc=createListener(_0x953f[12]+ _0x922cxb,_0x922cx8);ReportChatSessionEvents[_0x953f[13]](_0x922cxb,_0x922cxc);_0x922cx8[_0x953f[13]](_0x953f[14],removeListener(_0x922cxb,_0x922cxc))}};function createListener(_0x922cxb,_0x922cx8){return function(_0x922cxe){onSave(_0x922cx8,_0x922cxe)}}function removeListener(_0x922cxb,_0x922cxc){return function(){ReportChatSessionEvents[_0x953f[15]](_0x922cxb,_0x922cxc)}}function getChatQueues(_0x922cx11){return function(){switch(_0x922cx11[_0x953f[28]]){case _0x953f[25]:return User[_0x953f[24]](_0x922cx11[_0x953f[23]],{attributes:[_0x953f[16]]})[_0x953f[21]](Util[_0x953f[22]]({},{attributes:[_0x953f[16]],include:[{raw:true,model:User,attributes:[_0x953f[16]]}]}))[_0x953f[21]](function(_0x922cx12){var _0x922cx13=[];_0x922cx12[_0x953f[20]][_0x953f[19]](function(_0x922cx14){_0x922cx13= _[_0x953f[18]](_0x922cx13,_[_0x953f[17]](_0x922cx14.Users,_0x953f[16]))});return {queue:_[_0x953f[17]](_0x922cx12[_0x953f[20]],_0x953f[16]),memberid:_0x922cx13}});case _0x953f[27]:return User[_0x953f[24]](_0x922cx11[_0x953f[23]],{attributes:[_0x953f[16]]})[_0x953f[21]](function(_0x922cx15){return _0x922cx15[_0x953f[26]]({attributes:[_0x953f[16]]})})[_0x953f[21]](function(_0x922cx12){return {queue:_[_0x953f[17]](_0x922cx12,_0x953f[16]),memberid:_0x922cx11[_0x953f[23]]}});default:return {}}}}function onSave(_0x922cx8,_0x922cxe,_0x922cx17){return Promise[_0x953f[38]]([])[_0x953f[21]](getChatQueues(_0x922cx8))[_0x953f[21]](function(_0x922cx19){if(_0x922cx8[_0x953f[28]]=== _0x953f[32]|| _[_0x953f[34]](_0x922cx19[_0x953f[33]],_0x922cxe[_0x953f[33]])|| _[_0x953f[34]](_0x922cx19[_0x953f[35]],_0x922cxe[_0x953f[35]])){_0x922cx8[_0x953f[37]](_0x953f[36],_0x922cxe)}})[_0x953f[31]](function(_0x922cx18){console[_0x953f[30]](_0x953f[29],_0x922cx18)})}function onRemove(_0x922cx8,_0x922cxe,_0x922cx17){_0x922cx8[_0x953f[37]](_0x953f[39],_0x922cxe)}
\ No newline at end of file
+var _0x9953=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x2E\x2F\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x2E\x65\x76\x65\x6E\x74\x73","\x52\x65\x70\x6F\x72\x74\x43\x68\x61\x74\x53\x65\x73\x73\x69\x6F\x6E","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x55\x73\x65\x72","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x6C\x6F\x64\x61\x73\x68","\x62\x6C\x75\x65\x62\x69\x72\x64","\x73\x61\x76\x65","\x72\x65\x6D\x6F\x76\x65","\x72\x65\x67\x69\x73\x74\x65\x72","\x6C\x65\x6E\x67\x74\x68","\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x3A","\x6F\x6E","\x64\x69\x73\x63\x6F\x6E\x6E\x65\x63\x74","\x72\x65\x6D\x6F\x76\x65\x4C\x69\x73\x74\x65\x6E\x65\x72","\x69\x64","\x6D\x61\x70","\x75\x6E\x69\x6F\x6E","\x66\x6F\x72\x45\x61\x63\x68","\x72\x6F\x77\x73","\x74\x68\x65\x6E","\x67\x65\x74\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x75\x73\x65\x72\x49\x64","\x66\x69\x6E\x64\x42\x79\x49\x64","\x75\x73\x65\x72","\x67\x65\x74\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73","\x61\x67\x65\x6E\x74","\x72\x6F\x6C\x65","\x45\x72\x72\x6F\x72\x20\x66\x69\x6C\x74\x65\x72\x69\x6E\x67\x20\x72\x65\x70\x6F\x72\x74\x20\x63\x68\x61\x74\x20\x73\x65\x73\x73\x69\x6F\x6E\x73\x20\x61\x66\x74\x65\x72\x20\x73\x61\x76\x65","\x6C\x6F\x67","\x63\x61\x74\x63\x68","\x61\x64\x6D\x69\x6E","\x6D\x65\x6D\x62\x65\x72\x69\x64","\x69\x6E\x63\x6C\x75\x64\x65\x73","\x71\x75\x65\x75\x65","\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x3A\x73\x61\x76\x65","\x65\x6D\x69\x74","\x61\x6C\x6C","\x72\x65\x70\x6F\x72\x74\x5F\x63\x68\x61\x74\x5F\x73\x65\x73\x73\x69\x6F\x6E\x3A\x72\x65\x6D\x6F\x76\x65"];_0x9953[0];const ReportChatSessionEvents=require(_0x9953[1]);const ReportChatSession=require(_0x9953[3])[_0x9953[2]];const User=require(_0x9953[3])[_0x9953[4]];const Util=require(_0x9953[5]);const _=require(_0x9953[6]);const Promise=require(_0x9953[7]);var events=[_0x9953[8],_0x9953[9]];exports[_0x9953[10]]= function(_0xbeeex8){for(var _0xbeeex9=0,_0xbeeexa=events[_0x9953[11]];_0xbeeex9< _0xbeeexa;_0xbeeex9++){var _0xbeeexb=events[_0xbeeex9];var _0xbeeexc=createListener(_0x9953[12]+ _0xbeeexb,_0xbeeex8);ReportChatSessionEvents[_0x9953[13]](_0xbeeexb,_0xbeeexc);_0xbeeex8[_0x9953[13]](_0x9953[14],removeListener(_0xbeeexb,_0xbeeexc))}};function createListener(_0xbeeexb,_0xbeeex8){return function(_0xbeeexe){onSave(_0xbeeex8,_0xbeeexe)}}function removeListener(_0xbeeexb,_0xbeeexc){return function(){ReportChatSessionEvents[_0x9953[15]](_0xbeeexb,_0xbeeexc)}}function getChatQueues(_0xbeeex11){return function(){switch(_0xbeeex11[_0x9953[28]]){case _0x9953[25]:return User[_0x9953[24]](_0xbeeex11[_0x9953[23]],{attributes:[_0x9953[16]]})[_0x9953[21]](Util[_0x9953[22]]({},{attributes:[_0x9953[16]],include:[{raw:true,model:User,attributes:[_0x9953[16]]}]}))[_0x9953[21]](function(_0xbeeex12){var _0xbeeex13=[];_0xbeeex12[_0x9953[20]][_0x9953[19]](function(_0xbeeex14){_0xbeeex13= _[_0x9953[18]](_0xbeeex13,_[_0x9953[17]](_0xbeeex14.Users,_0x9953[16]))});return {queue:_[_0x9953[17]](_0xbeeex12[_0x9953[20]],_0x9953[16]),memberid:_0xbeeex13}});case _0x9953[27]:return User[_0x9953[24]](_0xbeeex11[_0x9953[23]],{attributes:[_0x9953[16]]})[_0x9953[21]](function(_0xbeeex15){return _0xbeeex15[_0x9953[26]]({attributes:[_0x9953[16]]})})[_0x9953[21]](function(_0xbeeex12){return {queue:_[_0x9953[17]](_0xbeeex12,_0x9953[16]),memberid:_0xbeeex11[_0x9953[23]]}});default:return {}}}}function onSave(_0xbeeex8,_0xbeeexe,_0xbeeex17){return Promise[_0x9953[38]]([])[_0x9953[21]](getChatQueues(_0xbeeex8))[_0x9953[21]](function(_0xbeeex19){if(_0xbeeex8[_0x9953[28]]=== _0x9953[32]|| _[_0x9953[34]](_0xbeeex19[_0x9953[33]],_0xbeeexe[_0x9953[33]])|| _[_0x9953[34]](_0xbeeex19[_0x9953[35]],_0xbeeexe[_0x9953[35]])){_0xbeeex8[_0x9953[37]](_0x9953[36],_0xbeeexe)}})[_0x9953[31]](function(_0xbeeex18){console[_0x9953[30]](_0x9953[29],_0xbeeex18)})}function onRemove(_0xbeeex8,_0xbeeexe,_0xbeeex17){_0xbeeex8[_0x9953[37]](_0x9953[39],_0xbeeexe)}
\ No newline at end of file