Built motion from commit e8da49ee.|2.6.33
[motion2.git] / server / services / ami / fax / util / util.js
index c01e9ee..1bb3c98 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x95fa=['message','inspect','ecm','headerinfo','minrate','maxrate','format','\x22%s\x22','modem','gateway','t38timeout','localstationid','path','variablesAction','uniqueid','originate','channel','xcally-motion-fax','from-sip','\x22%s\x22\x20<%s>','util','fax'];(function(_0x17d9e3,_0x1f969c){var _0x14192d=function(_0x159745){while(--_0x159745){_0x17d9e3['push'](_0x17d9e3['shift']());}};_0x14192d(++_0x1f969c);}(_0x95fa,0xda));var _0xa95f=function(_0x439518,_0x473f89){_0x439518=_0x439518-0x0;var _0x446a47=_0x95fa[_0x439518];return _0x446a47;};'use strict';var util=require(_0xa95f('0x0'));var _=require('lodash');var moment=require('moment');var logger=require('../../../../config/logger')(_0xa95f('0x1'));exports[_0xa95f('0x2')]=function(_0x424d1a){return{'message':_0x424d1a};};exports['logger']=function(_0x332c99,_0x4f31a6){logger['info'](_0x332c99,util[_0xa95f('0x3')](_0x4f31a6,{'showHidden':![],'depth':null}));};exports['addVariables']=function(_0x2e390f,_0x2022d0){var _0x1b4ee1={'XMF-ECM':_0x2022d0[_0xa95f('0x4')],'XMF-HEADERINFO':_0x2022d0[_0xa95f('0x5')],'XMF-MINRATE':_0x2022d0[_0xa95f('0x6')],'XMF-MAXRATE':_0x2022d0[_0xa95f('0x7')],'XMF-MODEM':util[_0xa95f('0x8')](_0xa95f('0x9'),_0x2022d0[_0xa95f('0xa')]),'XMF-GATEWAY':_0x2022d0[_0xa95f('0xb')],'XMF-FAXDETECT':_0x2022d0['faxdetect'],'XMF-T38TIMEOUT':_0x2022d0[_0xa95f('0xc')],'XMF-LOCALSTATIONID':_0x2022d0[_0xa95f('0xd')],'XMF-PATH':_0x2e390f[_0xa95f('0xe')]};return _0x1b4ee1;};exports[_0xa95f('0xf')]=function(_0x39f0fa,_0x2c197c){return{'actionid':_0x39f0fa[_0xa95f('0x10')],'action':_0xa95f('0x11'),'channel':_0x39f0fa[_0xa95f('0x12')],'Exten':_0xa95f('0x13'),'Context':_0xa95f('0x14'),'Priority':'1','callerid':util['format'](_0xa95f('0x15'),_0x39f0fa[_0xa95f('0x5')]?_0x39f0fa[_0xa95f('0x5')]:'',_0x39f0fa['localstationid']),'variable':_0x2c197c,'timeout':0x1e*0x3e8,'async':!![],'channelid':_0x39f0fa['uniqueid']};};
\ No newline at end of file
+var _0xc233=['path','variablesAction','uniqueid','originate','channel','from-sip','util','lodash','moment','../../../../config/logger','message','logger','addVariables','ecm','headerinfo','format','\x22%s\x22','modem','gateway','faxdetect','t38timeout','localstationid'];(function(_0x2ee285,_0x611be5){var _0x32e656=function(_0x1a63fb){while(--_0x1a63fb){_0x2ee285['push'](_0x2ee285['shift']());}};_0x32e656(++_0x611be5);}(_0xc233,0x150));var _0x3c23=function(_0x4b4b0e,_0x6c674){_0x4b4b0e=_0x4b4b0e-0x0;var _0x4c2d91=_0xc233[_0x4b4b0e];return _0x4c2d91;};'use strict';var util=require(_0x3c23('0x0'));var _=require(_0x3c23('0x1'));var moment=require(_0x3c23('0x2'));var logger=require(_0x3c23('0x3'))('fax');exports[_0x3c23('0x4')]=function(_0x32d930){return{'message':_0x32d930};};exports[_0x3c23('0x5')]=function(_0x701268,_0x292d11){logger['info'](_0x701268,util['inspect'](_0x292d11,{'showHidden':![],'depth':null}));};exports[_0x3c23('0x6')]=function(_0x4e41fc,_0x3da577){var _0x1c362c={'XMF-ECM':_0x3da577[_0x3c23('0x7')],'XMF-HEADERINFO':_0x3da577[_0x3c23('0x8')],'XMF-MINRATE':_0x3da577['minrate'],'XMF-MAXRATE':_0x3da577['maxrate'],'XMF-MODEM':util[_0x3c23('0x9')](_0x3c23('0xa'),_0x3da577[_0x3c23('0xb')]),'XMF-GATEWAY':_0x3da577[_0x3c23('0xc')],'XMF-FAXDETECT':_0x3da577[_0x3c23('0xd')],'XMF-T38TIMEOUT':_0x3da577[_0x3c23('0xe')],'XMF-LOCALSTATIONID':_0x3da577[_0x3c23('0xf')],'XMF-PATH':_0x4e41fc[_0x3c23('0x10')]};return _0x1c362c;};exports[_0x3c23('0x11')]=function(_0x19de56,_0x4318d2){return{'actionid':_0x19de56[_0x3c23('0x12')],'action':_0x3c23('0x13'),'channel':_0x19de56[_0x3c23('0x14')],'Exten':'xcally-motion-fax','Context':_0x3c23('0x15'),'Priority':'1','callerid':util['format']('\x22%s\x22\x20<%s>',_0x19de56[_0x3c23('0x8')]?_0x19de56[_0x3c23('0x8')]:'',_0x19de56[_0x3c23('0xf')]),'variable':_0x4318d2,'timeout':0x1e*0x3e8,'async':!![],'channelid':_0x19de56['uniqueid']};};
\ No newline at end of file